In [ ]:
#pip install pingouin
In [ ]:
import pandas as pd
import numpy as np
import matplotlib.pyplot as plt
import seaborn as sns
from sklearn.preprocessing import StandardScaler
from scipy.stats import zscore
import pingouin as pg
import statsmodels.api as sm
from statsmodels.stats.outliers_influence import variance_inflation_factor
from statsmodels.formula.api import mixedlm
import warnings
import os
In [ ]:
warnings.filterwarnings('ignore')
pd.set_option('display.max_rows', 50)
pd.set_option('display.max_columns', 500)
In [ ]:
os.chdir('C:/Users/Ryo/OneDrive/Desktop/Master Thesis/master_thesis/study3')
data preparation¶
prep for the response df¶
In [ ]:
file_loc = 'raw/Study3 - final_July_18_2024_02_35_final.xlsx'
df = pd.read_excel(file_loc)
df
Out[ ]:
| ResponseId | Ads_OP_1_Reversed | Ads_OP_2_Reversed | Ads_OP_3_Reversed | Ads_OP_4_Reversed | Ads_OP_5_Reversed | Ads_OP_6_Reversed | Ads_CO_1_Normal | Ads_CO_2_Normal | Ads_CO_3_Normal | Ads_CO_4_Normal | Ads_CO_5_Normal | Ads_CO_6_Normal | Ads_EX_1_Reversed | Ads_EX_2_Reversed | Ads_EX_3_Reversed | Ads_EX_4_Reversed | Ads_EX_5_Reversed | Ads_EX_6_Reversed | Ads_AG_1_Normal | Ads_AG_2_Normal | Ads_AG_3_Normal | Ads_AG_4_Normal | Ads_AG_5_Normal | Ads_AG_6_Normal | Desc_OP_1_Normal | Desc_CO_1_Reversed | Desc_EX_1_Normal | Desc_AG_1_Reversed | |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 0 | 5db4f0b63e33f2000dd54016 | 22 | 19 | 14 | 16 | 17 | 15 | 21 | 22 | 18 | 18 | 18 | 15 | 24 | 25 | 23 | 22 | 21 | 17 | 70 | 69 | 69 | 68 | 65 | 61 | 75 | 26 | 75 | 22 |
| 1 | 66294a585f1cf3fdaeb80120 | 28 | 50 | 47 | 72 | 50 | 41 | 34 | 50 | 50 | 59 | 46 | 21 | 46 | 50 | 58 | 62 | 55 | 38 | 56 | 50 | 55 | 64 | 58 | 60 | 91 | 90 | 80 | 40 |
| 2 | 665a52573b9527ce0011158b | 10 | 10 | 10 | 10 | 10 | 10 | 0 | 0 | 0 | 0 | 0 | 0 | 10 | 10 | 10 | 10 | 10 | 10 | 61 | 60 | 61 | 61 | 61 | 62 | 100 | 100 | 100 | 42 |
| 3 | 651ebcca48c60acc82f1f2bd | 60 | 50 | 63 | 90 | 90 | 89 | 31 | 50 | 34 | 50 | 39 | 37 | 62 | 50 | 65 | 80 | 70 | 79 | 62 | 50 | 54 | 67 | 67 | 77 | 82 | 82 | 82 | 34 |
| 4 | 6634fb892af2e227ab65f004 | 80 | 50 | 90 | 85 | 90 | 85 | 80 | 50 | 75 | 50 | 75 | 87 | 95 | 50 | 95 | 50 | 95 | 95 | 70 | 60 | 70 | 67 | 70 | 70 | 10 | 80 | 60 | 80 |
| ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... |
| 87 | 64d52f62a1f1a7371760fe4f | 82 | 64 | 86 | 72 | 79 | 90 | 40 | 44 | 24 | 37 | 31 | 15 | 39 | 31 | 21 | 21 | 13 | 13 | 81 | 73 | 91 | 68 | 81 | 89 | 20 | 70 | 83 | 32 |
| 88 | 66622736b3fcb6b8f3c04fdd | 88 | 86 | 92 | 83 | 86 | 85 | 28 | 41 | 11 | 28 | 28 | 16 | 81 | 78 | 87 | 81 | 75 | 86 | 68 | 66 | 70 | 61 | 70 | 66 | 76 | 26 | 68 | 30 |
| 89 | 6660680acd027329cecdf2b8 | 37 | 33 | 35 | 49 | 47 | 46 | 61 | 56 | 67 | 53 | 74 | 86 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
| 90 | 5d215a1bbf7f840019701939 | 53 | 52 | 70 | 62 | 75 | 82 | 35 | 49 | 28 | 40 | 31 | 33 | 69 | 69 | 77 | 64 | 69 | 68 | 53 | 54 | 55 | 51 | 50 | 50 | 51 | 52 | 53 | 53 |
| 91 | 663294f21bab6d7c3f7bf27b | 26 | 46 | 29 | 42 | 56 | 34 | 40 | 40 | 18 | 37 | 37 | 46 | 6 | 17 | 8 | 8 | 5 | 3 | 58 | 87 | 46 | 84 | 55 | 54 | 69 | 54 | 93 | 46 |
92 rows × 29 columns
In [ ]:
print(f"shape {df.shape}")
shape (92, 29)
In [ ]:
file_loc = 'raw/20240721_prolific_export.csv'
target_respondants = pd.read_csv(file_loc)
target_respondants = target_respondants[target_respondants['Status'] == 'APPROVED']['Participant id'].unique().tolist()
len(target_respondants)
Out[ ]:
90
In [ ]:
study3_respondants = df['ResponseId'].tolist()
print(f"original respondse counts: {len(study3_respondants)}")
# filter df to target participants
# Count non-null values for each row
df['non_null_count'] = df.notna().sum(axis=1)
# Sort by 'ResponseId' and 'non_null_count' (descending), then drop duplicates
df = df.sort_values(['ResponseId', 'non_null_count'], ascending=[True, False]).drop_duplicates('ResponseId')
# Remove the temporary 'non_null_count' column
df = df.drop('non_null_count', axis=1)
# Filter to keep only target respondents
s3_response_df = df[df['ResponseId'].isin(target_respondants)]
print(f"final respondse counts: {len(s3_response_df['ResponseId'])}")
original respondse counts: 92 final respondse counts: 90
In [ ]:
# Reverse scores for columns ending with '_Reversed'
reversed_columns = [col for col in s3_response_df.columns if col.endswith('_Reversed')]
for col in reversed_columns:
s3_response_df[col] = 100 - s3_response_df[col]
# Remove '_Normal' or '_Reversed' from all column names
s3_response_df.columns = s3_response_df.columns.str.replace('_Normal', '').str.replace('_Reversed', '')
# Display the modified DataFrame
s3_response_df
Out[ ]:
| ResponseId | Ads_OP_1 | Ads_OP_2 | Ads_OP_3 | Ads_OP_4 | Ads_OP_5 | Ads_OP_6 | Ads_CO_1 | Ads_CO_2 | Ads_CO_3 | Ads_CO_4 | Ads_CO_5 | Ads_CO_6 | Ads_EX_1 | Ads_EX_2 | Ads_EX_3 | Ads_EX_4 | Ads_EX_5 | Ads_EX_6 | Ads_AG_1 | Ads_AG_2 | Ads_AG_3 | Ads_AG_4 | Ads_AG_5 | Ads_AG_6 | Desc_OP_1 | Desc_CO_1 | Desc_EX_1 | Desc_AG_1 | |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 12 | 577f70d1454e5400015f1845 | 72 | 59 | 70 | 34 | 88 | 83 | 88 | 85 | 91 | 87 | 95 | 93 | 7 | 29 | 36 | 5 | 20 | 10 | 82 | 89 | 91 | 88 | 91 | 91 | 91 | 85 | 88 | 6 |
| 81 | 5a2adf6a8e00a000019864fb | 72 | 55 | 64 | 67 | 58 | 70 | 27 | 39 | 35 | 35 | 22 | 29 | 74 | 70 | 82 | 77 | 75 | 80 | 80 | 76 | 76 | 66 | 77 | 67 | 72 | 25 | 26 | 71 |
| 33 | 5aa806e7777df200016088c5 | 20 | 9 | 0 | 0 | 0 | 0 | 16 | 0 | 6 | 0 | 11 | 0 | 16 | 0 | 2 | 10 | 4 | 0 | 62 | 69 | 54 | 38 | 48 | 67 | 84 | 74 | 23 | 59 |
| 63 | 5afe053059ae1e00017e6a3c | 78 | 19 | 17 | 16 | 17 | 19 | 0 | 20 | 18 | 62 | 9 | 10 | 47 | 46 | 47 | 27 | 46 | 47 | 44 | 44 | 47 | 47 | 47 | 47 | 83 | 72 | 70 | 64 |
| 10 | 5b757a03976ecb0001b1168f | 8 | 19 | 0 | 0 | 0 | 0 | 64 | 73 | 73 | 65 | 68 | 70 | 27 | 39 | 14 | 8 | 17 | 7 | 71 | 84 | 77 | 68 | 92 | 93 | 45 | 27 | 81 | 42 |
| ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... |
| 82 | 66645cff5b7cb46819ac4d8a | 72 | 71 | 72 | 75 | 78 | 75 | 71 | 74 | 77 | 76 | 74 | 72 | 77 | 82 | 80 | 81 | 85 | 86 | 59 | 61 | 45 | 43 | 44 | 45 | 86 | 73 | 80 | 67 |
| 11 | 6664b0106c4f8ba1febc5a1a | 17 | 30 | 21 | 8 | 14 | 9 | 78 | 68 | 75 | 0 | 73 | 91 | 23 | 30 | 4 | 38 | 22 | 22 | 36 | 73 | 81 | 0 | 91 | 41 | 74 | 14 | 69 | 30 |
| 84 | 6665899df8740e0a2b6798fa | 16 | 8 | 11 | 6 | 10 | 14 | 89 | 93 | 86 | 88 | 91 | 88 | 15 | 5 | 12 | 10 | 10 | 8 | 94 | 90 | 87 | 90 | 92 | 88 | 91 | 75 | 88 | 79 |
| 19 | 666667f3e900925d27fe40d7 | 11 | 11 | 3 | 5 | 5 | 7 | 91 | 75 | 100 | 81 | 84 | 87 | 94 | 94 | 87 | 90 | 100 | 95 | 79 | 88 | 92 | 90 | 88 | 100 | 100 | 98 | 87 | 93 |
| 26 | 6669a1aedfa639b507eccff6 | 79 | 66 | 77 | 85 | 67 | 76 | 26 | 21 | 16 | 36 | 38 | 23 | 84 | 76 | 78 | 88 | 85 | 66 | 60 | 62 | 56 | 69 | 61 | 66 | 24 | 36 | 35 | 25 |
90 rows × 29 columns
prep for socioecnomic and big5 scores¶
In [ ]:
big5_file_loc = 'raw/big5_scores.csv'
big5_df = pd.read_csv(big5_file_loc)
big5_df.tail(5)
Out[ ]:
| ResponseId | Extraversion | Agreeableness | Conscientiousness | Neuroticism | Open_Mindedness | |
|---|---|---|---|---|---|---|
| 99 | 60a062ed4c4334abbbf32323 | 3.333333 | 3.000000 | 3.166667 | 3.666667 | 4.166667 |
| 100 | 5f3ac1732efa0a74f975b1a8 | 3.500000 | 4.833333 | 4.333333 | 1.000000 | 3.000000 |
| 101 | 6601b51675d287d6a62f11c4 | 3.666667 | 4.833333 | 4.333333 | 1.166667 | 4.666667 |
| 102 | 656f2e99bd2939f9b3f9d090 | 3.833333 | 4.000000 | 4.666667 | 1.666667 | 4.000000 |
| 103 | 6658822c0f5b1367a1585ee1 | 4.500000 | 4.666667 | 5.000000 | 1.333333 | 3.166667 |
In [ ]:
socioecono_file_loc = 'raw/socioecono_scores.csv'
socioecono_df = pd.read_csv(socioecono_file_loc)
socioecono_df.tail(5)
Out[ ]:
| ResponseId | gender | age | education | race | employment | income | |
|---|---|---|---|---|---|---|---|
| 99 | 60a062ed4c4334abbbf32323 | 2 | 27 | 4 | 2 | 1 | 1 |
| 100 | 5f3ac1732efa0a74f975b1a8 | 2 | 30 | 2 | 1 | 6 | 5 |
| 101 | 6601b51675d287d6a62f11c4 | 2 | 55 | 5 | 2 | 99 | 11 |
| 102 | 656f2e99bd2939f9b3f9d090 | 1 | 43 | 5 | 2 | 7 | 12 |
| 103 | 6658822c0f5b1367a1585ee1 | 2 | 43 | 5 | 2 | 7 | 8 |
In [ ]:
# filter socioecono_df and big5_df to study3 participants
socioecono_df = socioecono_df[socioecono_df['ResponseId'].isin(target_respondants)]
big5_df = big5_df[big5_df['ResponseId'].isin(target_respondants)]
print(f"row # for socioecono_df : {len(socioecono_df['ResponseId'])}, row # for big5_df : {len(big5_df['ResponseId'])}")
row # for socioecono_df : 90, row # for big5_df : 90
general analysis¶
In [ ]:
print(f"mean age {socioecono_df['age'].mean()} with sd {socioecono_df['age'].std()}, female % {socioecono_df[socioecono_df['gender']==1]['gender'].sum()/socioecono_df.shape[0]}")
mean age 40.86666666666667 with sd 11.74466170869495, female % 0.4777777777777778
In [ ]:
# Melt the DataFrame
big5_df_num = big5_df.iloc[:,1:]
big5_df_melted = big5_df_num.melt(var_name='Trait', value_name='Score')
# Create a violin plot
plt.figure(figsize=(10, 6))
sns.violinplot(x='Trait', y='Score', data=big5_df_melted, inner='quartile', palette='muted')
plt.title('Distribution of Scores for Each Trait')
plt.ylim(0, 5)
plt.xlabel('Trait')
plt.ylabel('Score')
plt.grid(True)
# Show the plot
plt.show()
generating distance_df for mixed personality trait¶
In [ ]:
# Extract rows where all Big 5 scores are greater than 3
big5_df_high_scorers = big5_df[
(big5_df['Extraversion'] > 3) &
(big5_df['Agreeableness'] > 3) &
(big5_df['Conscientiousness'] > 3) &
(big5_df['Open_Mindedness'] > 3)
]
# Display the result
print(f"Number of participants with targeted Big 5 scores > 3: {len(big5_df_high_scorers)}")
#print(big5_df_high_scorers)
Number of participants with targeted Big 5 scores > 3: 32
In [ ]:
# Extract rows where all Big 5 scores are greater than 3
big5_df_ex_high_scorers = big5_df[big5_df['Extraversion'] > 3]['ResponseId'].tolist()
big5_df_ag_high_scorers = big5_df[big5_df['Agreeableness'] > 3]['ResponseId'].tolist()
big5_df_co_high_scorers = big5_df[big5_df['Conscientiousness'] > 3]['ResponseId'].tolist()
big5_df_op_high_scorers = big5_df[big5_df['Open_Mindedness'] > 3]['ResponseId'].tolist()
# Display the result
print(f"Number of participants with op > 3: {len(big5_df_op_high_scorers)}")
print(f"Number of participants with co > 3: {len(big5_df_co_high_scorers)}")
print(f"Number of participants with ex > 3: {len(big5_df_ex_high_scorers)}")
print(f"Number of participants with ag > 3: {len(big5_df_ag_high_scorers)}")
big5_dfs_dict = {}
big5_dfs_dict['op'] = big5_df[big5_df['ResponseId'].isin(big5_df_op_high_scorers)]
big5_dfs_dict['co'] = big5_df[big5_df['ResponseId'].isin(big5_df_co_high_scorers)]
big5_dfs_dict['ex'] = big5_df[big5_df['ResponseId'].isin(big5_df_ex_high_scorers)]
big5_dfs_dict['ag'] = big5_df[big5_df['ResponseId'].isin(big5_df_ag_high_scorers)]
Number of participants with op > 3: 75 Number of participants with co > 3: 77 Number of participants with ex > 3: 46 Number of participants with ag > 3: 79
In [ ]:
socioecono_df_high_op = socioecono_df[socioecono_df['ResponseId'].isin(big5_df_op_high_scorers)]
socioecono_df_high_co = socioecono_df[socioecono_df['ResponseId'].isin(big5_df_co_high_scorers)]
socioecono_df_high_ex = socioecono_df[socioecono_df['ResponseId'].isin(big5_df_ex_high_scorers)]
socioecono_df_high_ag = socioecono_df[socioecono_df['ResponseId'].isin(big5_df_ag_high_scorers)]
print(f"OP: mean age {socioecono_df_high_op['age'].mean()} with sd {socioecono_df_high_op['age'].std()}, female % {socioecono_df_high_op[socioecono_df_high_op['gender']==1]['gender'].sum()/socioecono_df_high_op.shape[0]}")
print(f"CO: mean age {socioecono_df_high_co['age'].mean()} with sd {socioecono_df_high_co['age'].std()}, female % {socioecono_df_high_co[socioecono_df_high_co['gender']==1]['gender'].sum()/socioecono_df_high_co.shape[0]}")
print(f"EX: mean age {socioecono_df_high_ex['age'].mean()} with sd {socioecono_df_high_ex['age'].std()}, female % {socioecono_df_high_ex[socioecono_df_high_ex['gender']==1]['gender'].sum()/socioecono_df_high_ex.shape[0]}")
print(f"AG: mean age {socioecono_df_high_ag['age'].mean()} with sd {socioecono_df_high_ag['age'].std()}, female % {socioecono_df_high_ag[socioecono_df_high_ag['gender']==1]['gender'].sum()/socioecono_df_high_ag.shape[0]}")
socioecono_dfs_dict = {}
socioecono_dfs_dict['op'] = socioecono_df_high_op
socioecono_dfs_dict['co'] = socioecono_df_high_co
socioecono_dfs_dict['ex'] = socioecono_df_high_ex
socioecono_dfs_dict['ag'] = socioecono_df_high_ag
OP: mean age 40.653333333333336 with sd 11.715655191946228, female % 0.44 CO: mean age 41.675324675324674 with sd 12.262954008379054, female % 0.4935064935064935 EX: mean age 41.608695652173914 with sd 11.408531429241043, female % 0.5652173913043478 AG: mean age 40.40506329113924 with sd 11.88461512201834, female % 0.46835443037974683
In [ ]:
mixed_trait_scores = pd.read_csv('raw/mixed_trait_scores.csv')
mixed_trait_scores
Out[ ]:
| Extraversion | Agreeableness | Conscientiousness | Open_Mindedness | |
|---|---|---|---|---|
| 0 | 3.166667 | 4.0 | 4.0 | 3.833333 |
In [ ]:
big5_dfs_dict['op']
Out[ ]:
| ResponseId | Extraversion | Agreeableness | Conscientiousness | Neuroticism | Open_Mindedness | |
|---|---|---|---|---|---|---|
| 1 | 641357b26802e397b5627d5e | 3.833333 | 3.166667 | 4.166667 | 1.833333 | 4.166667 |
| 2 | 66294a585f1cf3fdaeb80120 | 4.166667 | 3.166667 | 4.666667 | 1.833333 | 3.166667 |
| 3 | 661571d6cc16ee34676734df | 3.166667 | 3.333333 | 3.000000 | 4.000000 | 4.166667 |
| 4 | 6629f95a14b6006e6a4b0aef | 3.000000 | 4.333333 | 3.500000 | 2.666667 | 4.166667 |
| 5 | 66463d8b1984a328f78252d7 | 3.166667 | 3.666667 | 2.333333 | 3.500000 | 5.000000 |
| ... | ... | ... | ... | ... | ... | ... |
| 94 | 666667f3e900925d27fe40d7 | 1.833333 | 2.000000 | 2.666667 | 4.333333 | 4.666667 |
| 95 | 63c0e1b1ee5ca75f61e3b2e1 | 4.500000 | 3.333333 | 3.833333 | 1.500000 | 4.000000 |
| 96 | 5d4a6459061e2a000138bad3 | 3.666667 | 4.333333 | 4.666667 | 2.166667 | 5.000000 |
| 101 | 6601b51675d287d6a62f11c4 | 3.666667 | 4.833333 | 4.333333 | 1.166667 | 4.666667 |
| 103 | 6658822c0f5b1367a1585ee1 | 4.500000 | 4.666667 | 5.000000 | 1.333333 | 3.166667 |
75 rows × 6 columns
In [ ]:
big5_dict = {'op': 'Open_Mindedness',
'co': 'Conscientiousness',
'ex': 'Extraversion',
'ag': 'Agreeableness'}
In [ ]:
def calculate_distance(df, mixed_scores, trait):
trait_full = big5_dict[trait]
return np.abs(df[trait_full] - mixed_scores[trait_full].values[0])
def calculate_distance_from_max(df, trait):
trait_full = big5_dict[trait]
return 5 - df[trait_full]
def generate_big5_distance_df(big5_df, mixed_trait_scores):
distances = pd.DataFrame(index=big5_df.index)
for trait in big5_dict.keys():
distances[f'{trait}_distance'] = calculate_distance(big5_df, mixed_trait_scores, trait)
distances[f'{trait}_distance_from_max'] = calculate_distance_from_max(big5_df, trait)
distances['total_distance'] = distances[[f'{trait}_distance' for trait in big5_dict.keys()]].sum(axis=1)
distance_columns = [f'{trait}_distance' for trait in big5_dict.keys()]
distances['average_distance'] = distances[distance_columns].mean(axis=1)
return pd.concat([big5_df['ResponseId'], distances], axis=1)
def generate_big5_distance_type_df(df, mixed_trait_scores):
distances = pd.DataFrame(index=df.index)
for trait in big5_dict.keys():
distances[f'{trait}_distance'] = calculate_distance(df, mixed_trait_scores, trait)
distances[f'{trait}_distance_from_max'] = calculate_distance_from_max(df, trait)
distances['total_distance'] = distances[[f'{trait}_distance' for trait in big5_dict.keys()]].sum(axis=1)
distance_columns = [f'{trait}_distance' for trait in big5_dict.keys()]
distances['average_distance'] = distances[distance_columns].mean(axis=1)
return pd.concat([df['ResponseId'], distances], axis=1)
# Generate big5_distance_df for all respondents
big5_distance_df = generate_big5_distance_df(big5_df, mixed_trait_scores)
# Generate big5_distance_{type} for each type
big5_distance_dfs_dict = {}
for type, df in big5_dfs_dict.items():
big5_distance_dfs_dict[type] = generate_big5_distance_type_df(df, mixed_trait_scores)
globals()[f'big5_distance_{type}'] = big5_distance_dfs_dict[type]
# Display summary statistics for the comprehensive DataFrame
print("Summary for all responses:")
print(big5_distance_df.describe())
print("\n")
# Display top 5 closest participants based on total distance for all responses
print("Top 5 closest participants for all responses based on total distance:")
print(big5_distance_df.sort_values('total_distance').head())
print("\n" + "="*50 + "\n")
# Display summary statistics and top 5 closest participants for each type
for type, df in big5_distance_dfs_dict.items():
print(f"Summary for {type.upper()}:")
print(df.describe())
print("\n")
print(f"Top 5 closest participants for {type.upper()} based on total distance:")
print(df.sort_values('total_distance').head())
print("\n" + "="*50 + "\n")
Summary for all responses:
op_distance op_distance_from_max co_distance co_distance_from_max \
count 90.000000 90.000000 90.000000 90.000000
mean 0.587037 1.235185 0.609259 1.038889
std 0.440766 0.733493 0.423381 0.743700
min 0.000000 0.000000 0.000000 0.000000
25% 0.333333 0.666667 0.333333 0.500000
50% 0.500000 1.166667 0.500000 1.000000
75% 0.833333 1.791667 0.833333 1.500000
max 2.666667 3.833333 2.166667 3.166667
ex_distance ex_distance_from_max ag_distance ag_distance_from_max \
count 90.000000 90.000000 90.000000 90.000000
mean 0.694444 1.920370 0.585185 1.081481
std 0.509124 0.859778 0.392059 0.702343
min 0.000000 0.000000 0.000000 0.000000
25% 0.333333 1.333333 0.333333 0.500000
50% 0.500000 1.833333 0.666667 1.000000
75% 1.000000 2.458333 0.833333 1.666667
max 1.833333 3.666667 2.000000 3.000000
total_distance average_distance
count 90.000000 90.000000
mean 2.475926 0.618981
std 0.988246 0.247061
min 0.500000 0.125000
25% 1.833333 0.458333
50% 2.333333 0.583333
75% 3.166667 0.791667
max 5.500000 1.375000
Top 5 closest participants for all responses based on total distance:
ResponseId op_distance op_distance_from_max co_distance \
80 6665899df8740e0a2b6798fa 0.000000 1.166667 0.000000
22 663192b96ab56cf1635615b7 0.000000 1.166667 0.166667
10 661f1144d35ac5240e53ad3f 0.166667 1.333333 0.000000
92 65aead8916eb9b7185ed25f3 0.500000 0.666667 0.500000
71 6664b0106c4f8ba1febc5a1a 0.166667 1.000000 0.333333
co_distance_from_max ex_distance ex_distance_from_max ag_distance \
80 1.000000 0.166667 2.000000 0.333333
22 0.833333 0.666667 2.500000 0.000000
10 1.000000 0.500000 1.333333 0.166667
92 0.500000 0.000000 1.833333 0.000000
71 0.666667 0.166667 1.666667 0.333333
ag_distance_from_max total_distance average_distance
80 0.666667 0.500000 0.125000
22 1.000000 0.833333 0.208333
10 0.833333 0.833333 0.208333
92 1.000000 1.000000 0.250000
71 1.333333 1.000000 0.250000
==================================================
Summary for OP:
op_distance op_distance_from_max co_distance co_distance_from_max \
count 75.000000 75.000000 75.000000 75.000000
mean 0.466667 1.011111 0.600000 1.000000
std 0.305112 0.537856 0.427121 0.739795
min 0.000000 0.000000 0.000000 0.000000
25% 0.166667 0.666667 0.333333 0.416667
50% 0.500000 1.000000 0.500000 1.000000
75% 0.666667 1.500000 0.833333 1.500000
max 1.166667 1.833333 2.166667 3.166667
ex_distance ex_distance_from_max ag_distance ag_distance_from_max \
count 75.000000 75.000000 75.000000 75.000000
mean 0.682222 1.826667 0.582222 1.102222
std 0.494848 0.846491 0.400238 0.702256
min 0.000000 0.000000 0.000000 0.000000
25% 0.333333 1.166667 0.333333 0.583333
50% 0.500000 1.833333 0.666667 1.000000
75% 1.000000 2.333333 0.833333 1.666667
max 1.833333 3.666667 2.000000 3.000000
total_distance average_distance
count 75.000000 75.000000
mean 2.331111 0.582778
std 0.944596 0.236149
min 0.500000 0.125000
25% 1.750000 0.437500
50% 2.166667 0.541667
75% 3.000000 0.750000
max 5.500000 1.375000
Top 5 closest participants for OP based on total distance:
ResponseId op_distance op_distance_from_max co_distance \
80 6665899df8740e0a2b6798fa 0.000000 1.166667 0.000000
22 663192b96ab56cf1635615b7 0.000000 1.166667 0.166667
10 661f1144d35ac5240e53ad3f 0.166667 1.333333 0.000000
92 65aead8916eb9b7185ed25f3 0.500000 0.666667 0.500000
71 6664b0106c4f8ba1febc5a1a 0.166667 1.000000 0.333333
co_distance_from_max ex_distance ex_distance_from_max ag_distance \
80 1.000000 0.166667 2.000000 0.333333
22 0.833333 0.666667 2.500000 0.000000
10 1.000000 0.500000 1.333333 0.166667
92 0.500000 0.000000 1.833333 0.000000
71 0.666667 0.166667 1.666667 0.333333
ag_distance_from_max total_distance average_distance
80 0.666667 0.500000 0.125000
22 1.000000 0.833333 0.208333
10 0.833333 0.833333 0.208333
92 1.000000 1.000000 0.250000
71 1.333333 1.000000 0.250000
==================================================
Summary for CO:
op_distance op_distance_from_max co_distance co_distance_from_max \
count 77.000000 77.000000 77.000000 77.000000
mean 0.577922 1.233766 0.493506 0.826840
std 0.451269 0.733124 0.311149 0.559632
min 0.000000 0.000000 0.000000 0.000000
25% 0.333333 0.666667 0.333333 0.333333
50% 0.500000 1.166667 0.500000 0.833333
75% 0.833333 1.666667 0.833333 1.333333
max 2.666667 3.833333 1.000000 1.833333
ex_distance ex_distance_from_max ag_distance ag_distance_from_max \
count 77.000000 77.000000 77.000000 77.000000
mean 0.696970 1.867965 0.571429 0.982684
std 0.495393 0.858113 0.352962 0.674615
min 0.000000 0.000000 0.000000 0.000000
25% 0.333333 1.333333 0.333333 0.333333
50% 0.500000 1.833333 0.666667 0.833333
75% 1.000000 2.333333 0.833333 1.500000
max 1.833333 3.666667 1.833333 2.833333
total_distance average_distance
count 77.000000 77.000000
mean 2.339827 0.584957
std 0.915446 0.228862
min 0.500000 0.125000
25% 1.666667 0.416667
50% 2.166667 0.541667
75% 3.000000 0.750000
max 4.333333 1.083333
Top 5 closest participants for CO based on total distance:
ResponseId op_distance op_distance_from_max co_distance \
80 6665899df8740e0a2b6798fa 0.000000 1.166667 0.000000
22 663192b96ab56cf1635615b7 0.000000 1.166667 0.166667
10 661f1144d35ac5240e53ad3f 0.166667 1.333333 0.000000
71 6664b0106c4f8ba1febc5a1a 0.166667 1.000000 0.333333
92 65aead8916eb9b7185ed25f3 0.500000 0.666667 0.500000
co_distance_from_max ex_distance ex_distance_from_max ag_distance \
80 1.000000 0.166667 2.000000 0.333333
22 0.833333 0.666667 2.500000 0.000000
10 1.000000 0.500000 1.333333 0.166667
71 0.666667 0.166667 1.666667 0.333333
92 0.500000 0.000000 1.833333 0.000000
ag_distance_from_max total_distance average_distance
80 0.666667 0.500000 0.125000
22 1.000000 0.833333 0.208333
10 0.833333 0.833333 0.208333
71 1.333333 1.000000 0.250000
92 1.000000 1.000000 0.250000
==================================================
Summary for EX:
op_distance op_distance_from_max co_distance co_distance_from_max \
count 46.000000 46.000000 46.000000 46.000000
mean 0.547101 1.090580 0.550725 0.833333
std 0.328977 0.638968 0.383083 0.654519
min 0.000000 0.000000 0.000000 0.000000
25% 0.333333 0.666667 0.333333 0.333333
50% 0.500000 1.000000 0.500000 0.666667
75% 0.833333 1.666667 0.833333 1.166667
max 1.166667 2.333333 1.666667 2.666667
ex_distance ex_distance_from_max ag_distance ag_distance_from_max \
count 46.000000 46.000000 46.000000 46.000000
mean 0.594203 1.239130 0.634058 1.039855
std 0.473563 0.473563 0.377810 0.743021
min 0.000000 0.000000 0.000000 0.000000
25% 0.166667 0.833333 0.333333 0.333333
50% 0.500000 1.333333 0.666667 1.000000
75% 1.000000 1.666667 0.833333 1.666667
max 1.833333 1.833333 1.833333 2.833333
total_distance average_distance
count 46.000000 46.000000
mean 2.326087 0.581522
std 0.859914 0.214979
min 0.833333 0.208333
25% 1.833333 0.458333
50% 2.333333 0.583333
75% 2.916667 0.729167
max 4.333333 1.083333
Top 5 closest participants for EX based on total distance:
ResponseId op_distance op_distance_from_max co_distance \
10 661f1144d35ac5240e53ad3f 0.166667 1.333333 0.000000
92 65aead8916eb9b7185ed25f3 0.500000 0.666667 0.500000
71 6664b0106c4f8ba1febc5a1a 0.166667 1.000000 0.333333
72 5c51d7f198b0ff000110dba8 0.000000 1.166667 0.333333
6 5d215a1bbf7f840019701939 0.833333 0.333333 0.166667
co_distance_from_max ex_distance ex_distance_from_max ag_distance \
10 1.000000 0.500000 1.333333 0.166667
92 0.500000 0.000000 1.833333 0.000000
71 0.666667 0.166667 1.666667 0.333333
72 0.666667 0.333333 1.500000 0.333333
6 0.833333 0.000000 1.833333 0.000000
ag_distance_from_max total_distance average_distance
10 0.833333 0.833333 0.208333
92 1.000000 1.000000 0.250000
71 1.333333 1.000000 0.250000
72 1.333333 1.000000 0.250000
6 1.000000 1.000000 0.250000
==================================================
Summary for AG:
op_distance op_distance_from_max co_distance co_distance_from_max \
count 79.000000 79.000000 79.000000 79.000000
mean 0.597046 1.236287 0.609705 1.010549
std 0.457299 0.751829 0.409021 0.737354
min 0.000000 0.000000 0.000000 0.000000
25% 0.333333 0.666667 0.333333 0.333333
50% 0.500000 1.166667 0.500000 1.000000
75% 0.833333 1.833333 0.833333 1.500000
max 2.666667 3.833333 2.166667 3.166667
ex_distance ex_distance_from_max ag_distance ag_distance_from_max \
count 79.000000 79.000000 79.000000 79.000000
mean 0.704641 1.930380 0.491561 0.917722
std 0.524302 0.876492 0.294657 0.569821
min 0.000000 0.000000 0.000000 0.000000
25% 0.250000 1.333333 0.333333 0.333333
50% 0.666667 1.833333 0.500000 1.000000
75% 1.000000 2.500000 0.666667 1.416667
max 1.833333 3.666667 1.000000 1.833333
total_distance average_distance
count 79.000000 79.000000
mean 2.402954 0.600738
std 0.943416 0.235854
min 0.500000 0.125000
25% 1.833333 0.458333
50% 2.333333 0.583333
75% 3.166667 0.791667
max 4.333333 1.083333
Top 5 closest participants for AG based on total distance:
ResponseId op_distance op_distance_from_max co_distance \
80 6665899df8740e0a2b6798fa 0.000000 1.166667 0.000000
22 663192b96ab56cf1635615b7 0.000000 1.166667 0.166667
10 661f1144d35ac5240e53ad3f 0.166667 1.333333 0.000000
92 65aead8916eb9b7185ed25f3 0.500000 0.666667 0.500000
71 6664b0106c4f8ba1febc5a1a 0.166667 1.000000 0.333333
co_distance_from_max ex_distance ex_distance_from_max ag_distance \
80 1.000000 0.166667 2.000000 0.333333
22 0.833333 0.666667 2.500000 0.000000
10 1.000000 0.500000 1.333333 0.166667
92 0.500000 0.000000 1.833333 0.000000
71 0.666667 0.166667 1.666667 0.333333
ag_distance_from_max total_distance average_distance
80 0.666667 0.500000 0.125000
22 1.000000 0.833333 0.208333
10 0.833333 0.833333 0.208333
92 1.000000 1.000000 0.250000
71 1.333333 1.000000 0.250000
==================================================
op_distance op_distance_from_max co_distance co_distance_from_max \
count 79.000000 79.000000 79.000000 79.000000
mean 0.597046 1.236287 0.609705 1.010549
std 0.457299 0.751829 0.409021 0.737354
min 0.000000 0.000000 0.000000 0.000000
25% 0.333333 0.666667 0.333333 0.333333
50% 0.500000 1.166667 0.500000 1.000000
75% 0.833333 1.833333 0.833333 1.500000
max 2.666667 3.833333 2.166667 3.166667
ex_distance ex_distance_from_max ag_distance ag_distance_from_max \
count 79.000000 79.000000 79.000000 79.000000
mean 0.704641 1.930380 0.491561 0.917722
std 0.524302 0.876492 0.294657 0.569821
min 0.000000 0.000000 0.000000 0.000000
25% 0.250000 1.333333 0.333333 0.333333
50% 0.666667 1.833333 0.500000 1.000000
75% 1.000000 2.500000 0.666667 1.416667
max 1.833333 3.666667 1.000000 1.833333
total_distance average_distance
count 79.000000 79.000000
mean 2.402954 0.600738
std 0.943416 0.235854
min 0.500000 0.125000
25% 1.833333 0.458333
50% 2.333333 0.583333
75% 3.166667 0.791667
max 4.333333 1.083333
Top 5 closest participants for AG based on total distance:
ResponseId op_distance op_distance_from_max co_distance \
80 6665899df8740e0a2b6798fa 0.000000 1.166667 0.000000
22 663192b96ab56cf1635615b7 0.000000 1.166667 0.166667
10 661f1144d35ac5240e53ad3f 0.166667 1.333333 0.000000
92 65aead8916eb9b7185ed25f3 0.500000 0.666667 0.500000
71 6664b0106c4f8ba1febc5a1a 0.166667 1.000000 0.333333
co_distance_from_max ex_distance ex_distance_from_max ag_distance \
80 1.000000 0.166667 2.000000 0.333333
22 0.833333 0.666667 2.500000 0.000000
10 1.000000 0.500000 1.333333 0.166667
92 0.500000 0.000000 1.833333 0.000000
71 0.666667 0.166667 1.666667 0.333333
ag_distance_from_max total_distance average_distance
80 0.666667 0.500000 0.125000
22 1.000000 0.833333 0.208333
10 0.833333 0.833333 0.208333
92 1.000000 1.000000 0.250000
71 1.333333 1.000000 0.250000
==================================================
In [ ]:
for key, value in big5_distance_dfs_dict.items():
print(key)
print(value.head())
print("")
op
ResponseId op_distance op_distance_from_max co_distance \
1 641357b26802e397b5627d5e 0.333333 0.833333 0.166667
2 66294a585f1cf3fdaeb80120 0.666667 1.833333 0.666667
3 661571d6cc16ee34676734df 0.333333 0.833333 1.000000
4 6629f95a14b6006e6a4b0aef 0.333333 0.833333 0.500000
5 66463d8b1984a328f78252d7 1.166667 0.000000 1.666667
co_distance_from_max ex_distance ex_distance_from_max ag_distance \
1 0.833333 0.666667 1.166667 0.833333
2 0.333333 1.000000 0.833333 0.833333
3 2.000000 0.000000 1.833333 0.666667
4 1.500000 0.166667 2.000000 0.333333
5 2.666667 0.000000 1.833333 0.333333
ag_distance_from_max total_distance average_distance
1 1.833333 2.000000 0.500000
2 1.833333 3.166667 0.791667
3 1.666667 2.000000 0.500000
4 0.666667 1.333333 0.333333
5 1.333333 3.166667 0.791667
co
ResponseId op_distance op_distance_from_max co_distance \
1 641357b26802e397b5627d5e 0.333333 0.833333 0.166667
2 66294a585f1cf3fdaeb80120 0.666667 1.833333 0.666667
4 6629f95a14b6006e6a4b0aef 0.333333 0.833333 0.500000
6 5d215a1bbf7f840019701939 0.833333 0.333333 0.166667
8 6601c47dbc5b1b7c9f1b3fde 0.333333 1.500000 0.166667
co_distance_from_max ex_distance ex_distance_from_max ag_distance \
1 0.833333 0.666667 1.166667 0.833333
2 0.333333 1.000000 0.833333 0.833333
4 1.500000 0.166667 2.000000 0.333333
6 0.833333 0.000000 1.833333 0.000000
8 0.833333 0.500000 2.333333 0.000000
ag_distance_from_max total_distance average_distance
1 1.833333 2.000000 0.500000
2 1.833333 3.166667 0.791667
4 0.666667 1.333333 0.333333
6 1.000000 1.000000 0.250000
8 1.000000 1.000000 0.250000
ex
ResponseId op_distance op_distance_from_max co_distance \
1 641357b26802e397b5627d5e 0.333333 0.833333 0.166667
2 66294a585f1cf3fdaeb80120 0.666667 1.833333 0.666667
3 661571d6cc16ee34676734df 0.333333 0.833333 1.000000
5 66463d8b1984a328f78252d7 1.166667 0.000000 1.666667
6 5d215a1bbf7f840019701939 0.833333 0.333333 0.166667
co_distance_from_max ex_distance ex_distance_from_max ag_distance \
1 0.833333 0.666667 1.166667 0.833333
2 0.333333 1.000000 0.833333 0.833333
3 2.000000 0.000000 1.833333 0.666667
5 2.666667 0.000000 1.833333 0.333333
6 0.833333 0.000000 1.833333 0.000000
ag_distance_from_max total_distance average_distance
1 1.833333 2.000000 0.500000
2 1.833333 3.166667 0.791667
3 1.666667 2.000000 0.500000
5 1.333333 3.166667 0.791667
6 1.000000 1.000000 0.250000
ag
ResponseId op_distance op_distance_from_max co_distance \
1 641357b26802e397b5627d5e 0.333333 0.833333 0.166667
2 66294a585f1cf3fdaeb80120 0.666667 1.833333 0.666667
3 661571d6cc16ee34676734df 0.333333 0.833333 1.000000
4 6629f95a14b6006e6a4b0aef 0.333333 0.833333 0.500000
5 66463d8b1984a328f78252d7 1.166667 0.000000 1.666667
co_distance_from_max ex_distance ex_distance_from_max ag_distance \
1 0.833333 0.666667 1.166667 0.833333
2 0.333333 1.000000 0.833333 0.833333
3 2.000000 0.000000 1.833333 0.666667
4 1.500000 0.166667 2.000000 0.333333
5 2.666667 0.000000 1.833333 0.333333
ag_distance_from_max total_distance average_distance
1 1.833333 2.000000 0.500000
2 1.833333 3.166667 0.791667
3 1.666667 2.000000 0.500000
4 0.666667 1.333333 0.333333
5 1.333333 3.166667 0.791667
In [ ]:
from_max_cols = ['op_distance_from_max',
'co_distance_from_max',
'ex_distance_from_max',
'ag_distance_from_max']
big5_distance_dfs_dict['op'][from_max_cols[0]].hist()
#big5_distance_dfs_dict['op']
Out[ ]:
<Axes: >
In [ ]:
op_filtered_rows = big5_distance_dfs_dict['op'][big5_distance_dfs_dict['op'][from_max_cols[0]] < 1]
co_filtered_rows = big5_distance_dfs_dict['co'][big5_distance_dfs_dict['co'][from_max_cols[1]] < 1]
ex_filtered_rows = big5_distance_dfs_dict['ex'][big5_distance_dfs_dict['ex'][from_max_cols[2]] < 1]
ag_filtered_rows = big5_distance_dfs_dict['ag'][big5_distance_dfs_dict['ag'][from_max_cols[3]] < 1]
print(f"op: {op_filtered_rows.shape[0]}")
print(f"co: {co_filtered_rows.shape[0]}")
print(f"ex: {ex_filtered_rows.shape[0]}")
print(f"ag: {ag_filtered_rows.shape[0]}")
op: 35 co: 42 ex: 15 ag: 39 co: 42 ex: 15 ag: 39
In [ ]:
big5_distance_df['average_distance'].hist()
Out[ ]:
<Axes: >
In [ ]:
big5_distance_dfs_dict['op']
Out[ ]:
| ResponseId | op_distance | op_distance_from_max | co_distance | co_distance_from_max | ex_distance | ex_distance_from_max | ag_distance | ag_distance_from_max | total_distance | average_distance | |
|---|---|---|---|---|---|---|---|---|---|---|---|
| 1 | 641357b26802e397b5627d5e | 0.333333 | 0.833333 | 0.166667 | 0.833333 | 0.666667 | 1.166667 | 0.833333 | 1.833333 | 2.000000 | 0.500000 |
| 2 | 66294a585f1cf3fdaeb80120 | 0.666667 | 1.833333 | 0.666667 | 0.333333 | 1.000000 | 0.833333 | 0.833333 | 1.833333 | 3.166667 | 0.791667 |
| 3 | 661571d6cc16ee34676734df | 0.333333 | 0.833333 | 1.000000 | 2.000000 | 0.000000 | 1.833333 | 0.666667 | 1.666667 | 2.000000 | 0.500000 |
| 4 | 6629f95a14b6006e6a4b0aef | 0.333333 | 0.833333 | 0.500000 | 1.500000 | 0.166667 | 2.000000 | 0.333333 | 0.666667 | 1.333333 | 0.333333 |
| 5 | 66463d8b1984a328f78252d7 | 1.166667 | 0.000000 | 1.666667 | 2.666667 | 0.000000 | 1.833333 | 0.333333 | 1.333333 | 3.166667 | 0.791667 |
| ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... |
| 94 | 666667f3e900925d27fe40d7 | 0.833333 | 0.333333 | 1.333333 | 2.333333 | 1.333333 | 3.166667 | 2.000000 | 3.000000 | 5.500000 | 1.375000 |
| 95 | 63c0e1b1ee5ca75f61e3b2e1 | 0.166667 | 1.000000 | 0.166667 | 1.166667 | 1.333333 | 0.500000 | 0.666667 | 1.666667 | 2.333333 | 0.583333 |
| 96 | 5d4a6459061e2a000138bad3 | 1.166667 | 0.000000 | 0.666667 | 0.333333 | 0.500000 | 1.333333 | 0.333333 | 0.666667 | 2.666667 | 0.666667 |
| 101 | 6601b51675d287d6a62f11c4 | 0.833333 | 0.333333 | 0.333333 | 0.666667 | 0.500000 | 1.333333 | 0.833333 | 0.166667 | 2.500000 | 0.625000 |
| 103 | 6658822c0f5b1367a1585ee1 | 0.666667 | 1.833333 | 1.000000 | 0.000000 | 1.333333 | 0.500000 | 0.666667 | 0.333333 | 3.666667 | 0.916667 |
75 rows × 11 columns
data prep for mixed effect model¶
In [ ]:
big5_distance_df
Out[ ]:
| ResponseId | op_distance | op_distance_from_max | co_distance | co_distance_from_max | ex_distance | ex_distance_from_max | ag_distance | ag_distance_from_max | total_distance | average_distance | |
|---|---|---|---|---|---|---|---|---|---|---|---|
| 1 | 641357b26802e397b5627d5e | 0.333333 | 0.833333 | 0.166667 | 0.833333 | 0.666667 | 1.166667 | 0.833333 | 1.833333 | 2.000000 | 0.500000 |
| 2 | 66294a585f1cf3fdaeb80120 | 0.666667 | 1.833333 | 0.666667 | 0.333333 | 1.000000 | 0.833333 | 0.833333 | 1.833333 | 3.166667 | 0.791667 |
| 3 | 661571d6cc16ee34676734df | 0.333333 | 0.833333 | 1.000000 | 2.000000 | 0.000000 | 1.833333 | 0.666667 | 1.666667 | 2.000000 | 0.500000 |
| 4 | 6629f95a14b6006e6a4b0aef | 0.333333 | 0.833333 | 0.500000 | 1.500000 | 0.166667 | 2.000000 | 0.333333 | 0.666667 | 1.333333 | 0.333333 |
| 5 | 66463d8b1984a328f78252d7 | 1.166667 | 0.000000 | 1.666667 | 2.666667 | 0.000000 | 1.833333 | 0.333333 | 1.333333 | 3.166667 | 0.791667 |
| ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... |
| 96 | 5d4a6459061e2a000138bad3 | 1.166667 | 0.000000 | 0.666667 | 0.333333 | 0.500000 | 1.333333 | 0.333333 | 0.666667 | 2.666667 | 0.666667 |
| 98 | 62b473736986d2b27c1427d2 | 1.166667 | 2.333333 | 0.333333 | 1.333333 | 1.000000 | 0.833333 | 0.500000 | 1.500000 | 3.000000 | 0.750000 |
| 100 | 5f3ac1732efa0a74f975b1a8 | 0.833333 | 2.000000 | 0.333333 | 0.666667 | 0.333333 | 1.500000 | 0.833333 | 0.166667 | 2.333333 | 0.583333 |
| 101 | 6601b51675d287d6a62f11c4 | 0.833333 | 0.333333 | 0.333333 | 0.666667 | 0.500000 | 1.333333 | 0.833333 | 0.166667 | 2.500000 | 0.625000 |
| 103 | 6658822c0f5b1367a1585ee1 | 0.666667 | 1.833333 | 1.000000 | 0.000000 | 1.333333 | 0.500000 | 0.666667 | 0.333333 | 3.666667 | 0.916667 |
90 rows × 11 columns
In [ ]:
s3_response_df
Out[ ]:
| ResponseId | Ads_OP_1 | Ads_OP_2 | Ads_OP_3 | Ads_OP_4 | Ads_OP_5 | Ads_OP_6 | Ads_CO_1 | Ads_CO_2 | Ads_CO_3 | Ads_CO_4 | Ads_CO_5 | Ads_CO_6 | Ads_EX_1 | Ads_EX_2 | Ads_EX_3 | Ads_EX_4 | Ads_EX_5 | Ads_EX_6 | Ads_AG_1 | Ads_AG_2 | Ads_AG_3 | Ads_AG_4 | Ads_AG_5 | Ads_AG_6 | Desc_OP_1 | Desc_CO_1 | Desc_EX_1 | Desc_AG_1 | |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 12 | 577f70d1454e5400015f1845 | 72 | 59 | 70 | 34 | 88 | 83 | 88 | 85 | 91 | 87 | 95 | 93 | 7 | 29 | 36 | 5 | 20 | 10 | 82 | 89 | 91 | 88 | 91 | 91 | 91 | 85 | 88 | 6 |
| 81 | 5a2adf6a8e00a000019864fb | 72 | 55 | 64 | 67 | 58 | 70 | 27 | 39 | 35 | 35 | 22 | 29 | 74 | 70 | 82 | 77 | 75 | 80 | 80 | 76 | 76 | 66 | 77 | 67 | 72 | 25 | 26 | 71 |
| 33 | 5aa806e7777df200016088c5 | 20 | 9 | 0 | 0 | 0 | 0 | 16 | 0 | 6 | 0 | 11 | 0 | 16 | 0 | 2 | 10 | 4 | 0 | 62 | 69 | 54 | 38 | 48 | 67 | 84 | 74 | 23 | 59 |
| 63 | 5afe053059ae1e00017e6a3c | 78 | 19 | 17 | 16 | 17 | 19 | 0 | 20 | 18 | 62 | 9 | 10 | 47 | 46 | 47 | 27 | 46 | 47 | 44 | 44 | 47 | 47 | 47 | 47 | 83 | 72 | 70 | 64 |
| 10 | 5b757a03976ecb0001b1168f | 8 | 19 | 0 | 0 | 0 | 0 | 64 | 73 | 73 | 65 | 68 | 70 | 27 | 39 | 14 | 8 | 17 | 7 | 71 | 84 | 77 | 68 | 92 | 93 | 45 | 27 | 81 | 42 |
| ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... |
| 82 | 66645cff5b7cb46819ac4d8a | 72 | 71 | 72 | 75 | 78 | 75 | 71 | 74 | 77 | 76 | 74 | 72 | 77 | 82 | 80 | 81 | 85 | 86 | 59 | 61 | 45 | 43 | 44 | 45 | 86 | 73 | 80 | 67 |
| 11 | 6664b0106c4f8ba1febc5a1a | 17 | 30 | 21 | 8 | 14 | 9 | 78 | 68 | 75 | 0 | 73 | 91 | 23 | 30 | 4 | 38 | 22 | 22 | 36 | 73 | 81 | 0 | 91 | 41 | 74 | 14 | 69 | 30 |
| 84 | 6665899df8740e0a2b6798fa | 16 | 8 | 11 | 6 | 10 | 14 | 89 | 93 | 86 | 88 | 91 | 88 | 15 | 5 | 12 | 10 | 10 | 8 | 94 | 90 | 87 | 90 | 92 | 88 | 91 | 75 | 88 | 79 |
| 19 | 666667f3e900925d27fe40d7 | 11 | 11 | 3 | 5 | 5 | 7 | 91 | 75 | 100 | 81 | 84 | 87 | 94 | 94 | 87 | 90 | 100 | 95 | 79 | 88 | 92 | 90 | 88 | 100 | 100 | 98 | 87 | 93 |
| 26 | 6669a1aedfa639b507eccff6 | 79 | 66 | 77 | 85 | 67 | 76 | 26 | 21 | 16 | 36 | 38 | 23 | 84 | 76 | 78 | 88 | 85 | 66 | 60 | 62 | 56 | 69 | 61 | 66 | 24 | 36 | 35 | 25 |
90 rows × 29 columns
In [ ]:
# Merge big5_distance_df and s3_response_df on ResponseId
merged_df = pd.merge(big5_distance_df, s3_response_df, on='ResponseId', how='inner')
# Rename columns in the merged dataframe
column_mapping = {
'op_distance': 'OP_distance',
'op_distance_from_max': 'OP_distance_from_max',
'co_distance': 'CO_distance',
'co_distance_from_max': 'CO_distance_from_max',
'ex_distance': 'EX_distance',
'ex_distance_from_max': 'EX_distance_from_max',
'ag_distance': 'AG_distance',
'ag_distance_from_max': 'AG_distance_from_max'
}
merged_df = merged_df.rename(columns=column_mapping)
# Display the column names to verify the changes
print("\nColumn names:")
print(merged_df.columns)
Column names:
Index(['ResponseId', 'OP_distance', 'OP_distance_from_max', 'CO_distance',
'CO_distance_from_max', 'EX_distance', 'EX_distance_from_max',
'AG_distance', 'AG_distance_from_max', 'total_distance',
'average_distance', 'Ads_OP_1', 'Ads_OP_2', 'Ads_OP_3', 'Ads_OP_4',
'Ads_OP_5', 'Ads_OP_6', 'Ads_CO_1', 'Ads_CO_2', 'Ads_CO_3', 'Ads_CO_4',
'Ads_CO_5', 'Ads_CO_6', 'Ads_EX_1', 'Ads_EX_2', 'Ads_EX_3', 'Ads_EX_4',
'Ads_EX_5', 'Ads_EX_6', 'Ads_AG_1', 'Ads_AG_2', 'Ads_AG_3', 'Ads_AG_4',
'Ads_AG_5', 'Ads_AG_6', 'Desc_OP_1', 'Desc_CO_1', 'Desc_EX_1',
'Desc_AG_1'],
dtype='object')
In [ ]:
merged_df
Out[ ]:
| ResponseId | OP_distance | OP_distance_from_max | CO_distance | CO_distance_from_max | EX_distance | EX_distance_from_max | AG_distance | AG_distance_from_max | total_distance | average_distance | Ads_OP_1 | Ads_OP_2 | Ads_OP_3 | Ads_OP_4 | Ads_OP_5 | Ads_OP_6 | Ads_CO_1 | Ads_CO_2 | Ads_CO_3 | Ads_CO_4 | Ads_CO_5 | Ads_CO_6 | Ads_EX_1 | Ads_EX_2 | Ads_EX_3 | Ads_EX_4 | Ads_EX_5 | Ads_EX_6 | Ads_AG_1 | Ads_AG_2 | Ads_AG_3 | Ads_AG_4 | Ads_AG_5 | Ads_AG_6 | Desc_OP_1 | Desc_CO_1 | Desc_EX_1 | Desc_AG_1 | |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 0 | 641357b26802e397b5627d5e | 0.333333 | 0.833333 | 0.166667 | 0.833333 | 0.666667 | 1.166667 | 0.833333 | 1.833333 | 2.000000 | 0.500000 | 89 | 75 | 89 | 84 | 71 | 75 | 81 | 66 | 74 | 77 | 79 | 82 | 72 | 68 | 67 | 68 | 76 | 69 | 71 | 78 | 70 | 68 | 85 | 84 | 63 | 50 | 53 | 50 |
| 1 | 66294a585f1cf3fdaeb80120 | 0.666667 | 1.833333 | 0.666667 | 0.333333 | 1.000000 | 0.833333 | 0.833333 | 1.833333 | 3.166667 | 0.791667 | 72 | 50 | 53 | 28 | 50 | 59 | 34 | 50 | 50 | 59 | 46 | 21 | 54 | 50 | 42 | 38 | 45 | 62 | 56 | 50 | 55 | 64 | 58 | 60 | 91 | 10 | 80 | 60 |
| 2 | 661571d6cc16ee34676734df | 0.333333 | 0.833333 | 1.000000 | 2.000000 | 0.000000 | 1.833333 | 0.666667 | 1.666667 | 2.000000 | 0.500000 | 29 | 49 | 37 | 45 | 34 | 31 | 60 | 60 | 58 | 59 | 62 | 80 | 61 | 100 | 56 | 57 | 61 | 67 | 65 | 59 | 59 | 59 | 65 | 71 | 28 | 49 | 57 | 57 |
| 3 | 6629f95a14b6006e6a4b0aef | 0.333333 | 0.833333 | 0.500000 | 1.500000 | 0.166667 | 2.000000 | 0.333333 | 0.666667 | 1.333333 | 0.333333 | 37 | 37 | 40 | 42 | 40 | 41 | 64 | 66 | 71 | 60 | 66 | 66 | 33 | 34 | 38 | 35 | 36 | 35 | 64 | 62 | 59 | 60 | 62 | 66 | 68 | 62 | 65 | 36 |
| 4 | 66463d8b1984a328f78252d7 | 1.166667 | 0.000000 | 1.666667 | 2.666667 | 0.000000 | 1.833333 | 0.333333 | 1.333333 | 3.166667 | 0.791667 | 13 | 39 | 33 | 23 | 40 | 15 | 81 | 73 | 77 | 85 | 61 | 84 | 16 | 21 | 20 | 30 | 14 | 26 | 20 | 40 | 8 | 28 | 18 | 16 | 14 | 94 | 65 | 9 |
| ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... |
| 85 | 5d4a6459061e2a000138bad3 | 1.166667 | 0.000000 | 0.666667 | 0.333333 | 0.500000 | 1.333333 | 0.333333 | 0.666667 | 2.666667 | 0.666667 | 48 | 73 | 48 | 48 | 48 | 47 | 11 | 40 | 10 | 10 | 9 | 10 | 93 | 52 | 96 | 95 | 95 | 95 | 14 | 80 | 14 | 46 | 17 | 44 | 7 | 26 | 54 | 47 |
| 86 | 62b473736986d2b27c1427d2 | 1.166667 | 2.333333 | 0.333333 | 1.333333 | 1.000000 | 0.833333 | 0.500000 | 1.500000 | 3.000000 | 0.750000 | 72 | 27 | 27 | 40 | 17 | 30 | 71 | 88 | 26 | 26 | 68 | 82 | 33 | 15 | 76 | 30 | 70 | 13 | 74 | 26 | 66 | 25 | 68 | 45 | 21 | 28 | 84 | 68 |
| 87 | 5f3ac1732efa0a74f975b1a8 | 0.833333 | 2.000000 | 0.333333 | 0.666667 | 0.333333 | 1.500000 | 0.833333 | 0.166667 | 2.333333 | 0.583333 | 5 | 14 | 0 | 3 | 31 | 0 | 24 | 0 | 26 | 0 | 46 | 0 | 29 | 1 | 3 | 50 | 28 | 23 | 81 | 58 | 77 | 60 | 51 | 59 | 100 | 59 | 0 | 11 |
| 88 | 6601b51675d287d6a62f11c4 | 0.833333 | 0.333333 | 0.333333 | 0.666667 | 0.500000 | 1.333333 | 0.833333 | 0.166667 | 2.500000 | 0.625000 | 18 | 44 | 19 | 23 | 20 | 24 | 33 | 45 | 34 | 40 | 39 | 35 | 18 | 40 | 17 | 17 | 20 | 22 | 71 | 83 | 79 | 75 | 82 | 89 | 45 | 44 | 83 | 57 |
| 89 | 6658822c0f5b1367a1585ee1 | 0.666667 | 1.833333 | 1.000000 | 0.000000 | 1.333333 | 0.500000 | 0.666667 | 0.333333 | 3.666667 | 0.916667 | 40 | 50 | 40 | 40 | 40 | 40 | 80 | 80 | 80 | 85 | 90 | 90 | 90 | 50 | 90 | 80 | 100 | 90 | 60 | 70 | 60 | 50 | 70 | 70 | 40 | 70 | 60 | 70 |
90 rows × 39 columns
In [ ]:
merged_df
Out[ ]:
| ResponseId | OP_distance | OP_distance_from_max | CO_distance | CO_distance_from_max | EX_distance | EX_distance_from_max | AG_distance | AG_distance_from_max | total_distance | average_distance | Ads_OP_1 | Ads_OP_2 | Ads_OP_3 | Ads_OP_4 | Ads_OP_5 | Ads_OP_6 | Ads_CO_1 | Ads_CO_2 | Ads_CO_3 | Ads_CO_4 | Ads_CO_5 | Ads_CO_6 | Ads_EX_1 | Ads_EX_2 | Ads_EX_3 | Ads_EX_4 | Ads_EX_5 | Ads_EX_6 | Ads_AG_1 | Ads_AG_2 | Ads_AG_3 | Ads_AG_4 | Ads_AG_5 | Ads_AG_6 | Desc_OP_1 | Desc_CO_1 | Desc_EX_1 | Desc_AG_1 | |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 0 | 641357b26802e397b5627d5e | 0.333333 | 0.833333 | 0.166667 | 0.833333 | 0.666667 | 1.166667 | 0.833333 | 1.833333 | 2.000000 | 0.500000 | 89 | 75 | 89 | 84 | 71 | 75 | 81 | 66 | 74 | 77 | 79 | 82 | 72 | 68 | 67 | 68 | 76 | 69 | 71 | 78 | 70 | 68 | 85 | 84 | 63 | 50 | 53 | 50 |
| 1 | 66294a585f1cf3fdaeb80120 | 0.666667 | 1.833333 | 0.666667 | 0.333333 | 1.000000 | 0.833333 | 0.833333 | 1.833333 | 3.166667 | 0.791667 | 72 | 50 | 53 | 28 | 50 | 59 | 34 | 50 | 50 | 59 | 46 | 21 | 54 | 50 | 42 | 38 | 45 | 62 | 56 | 50 | 55 | 64 | 58 | 60 | 91 | 10 | 80 | 60 |
| 2 | 661571d6cc16ee34676734df | 0.333333 | 0.833333 | 1.000000 | 2.000000 | 0.000000 | 1.833333 | 0.666667 | 1.666667 | 2.000000 | 0.500000 | 29 | 49 | 37 | 45 | 34 | 31 | 60 | 60 | 58 | 59 | 62 | 80 | 61 | 100 | 56 | 57 | 61 | 67 | 65 | 59 | 59 | 59 | 65 | 71 | 28 | 49 | 57 | 57 |
| 3 | 6629f95a14b6006e6a4b0aef | 0.333333 | 0.833333 | 0.500000 | 1.500000 | 0.166667 | 2.000000 | 0.333333 | 0.666667 | 1.333333 | 0.333333 | 37 | 37 | 40 | 42 | 40 | 41 | 64 | 66 | 71 | 60 | 66 | 66 | 33 | 34 | 38 | 35 | 36 | 35 | 64 | 62 | 59 | 60 | 62 | 66 | 68 | 62 | 65 | 36 |
| 4 | 66463d8b1984a328f78252d7 | 1.166667 | 0.000000 | 1.666667 | 2.666667 | 0.000000 | 1.833333 | 0.333333 | 1.333333 | 3.166667 | 0.791667 | 13 | 39 | 33 | 23 | 40 | 15 | 81 | 73 | 77 | 85 | 61 | 84 | 16 | 21 | 20 | 30 | 14 | 26 | 20 | 40 | 8 | 28 | 18 | 16 | 14 | 94 | 65 | 9 |
| ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... |
| 85 | 5d4a6459061e2a000138bad3 | 1.166667 | 0.000000 | 0.666667 | 0.333333 | 0.500000 | 1.333333 | 0.333333 | 0.666667 | 2.666667 | 0.666667 | 48 | 73 | 48 | 48 | 48 | 47 | 11 | 40 | 10 | 10 | 9 | 10 | 93 | 52 | 96 | 95 | 95 | 95 | 14 | 80 | 14 | 46 | 17 | 44 | 7 | 26 | 54 | 47 |
| 86 | 62b473736986d2b27c1427d2 | 1.166667 | 2.333333 | 0.333333 | 1.333333 | 1.000000 | 0.833333 | 0.500000 | 1.500000 | 3.000000 | 0.750000 | 72 | 27 | 27 | 40 | 17 | 30 | 71 | 88 | 26 | 26 | 68 | 82 | 33 | 15 | 76 | 30 | 70 | 13 | 74 | 26 | 66 | 25 | 68 | 45 | 21 | 28 | 84 | 68 |
| 87 | 5f3ac1732efa0a74f975b1a8 | 0.833333 | 2.000000 | 0.333333 | 0.666667 | 0.333333 | 1.500000 | 0.833333 | 0.166667 | 2.333333 | 0.583333 | 5 | 14 | 0 | 3 | 31 | 0 | 24 | 0 | 26 | 0 | 46 | 0 | 29 | 1 | 3 | 50 | 28 | 23 | 81 | 58 | 77 | 60 | 51 | 59 | 100 | 59 | 0 | 11 |
| 88 | 6601b51675d287d6a62f11c4 | 0.833333 | 0.333333 | 0.333333 | 0.666667 | 0.500000 | 1.333333 | 0.833333 | 0.166667 | 2.500000 | 0.625000 | 18 | 44 | 19 | 23 | 20 | 24 | 33 | 45 | 34 | 40 | 39 | 35 | 18 | 40 | 17 | 17 | 20 | 22 | 71 | 83 | 79 | 75 | 82 | 89 | 45 | 44 | 83 | 57 |
| 89 | 6658822c0f5b1367a1585ee1 | 0.666667 | 1.833333 | 1.000000 | 0.000000 | 1.333333 | 0.500000 | 0.666667 | 0.333333 | 3.666667 | 0.916667 | 40 | 50 | 40 | 40 | 40 | 40 | 80 | 80 | 80 | 85 | 90 | 90 | 90 | 50 | 90 | 80 | 100 | 90 | 60 | 70 | 60 | 50 | 70 | 70 | 40 | 70 | 60 | 70 |
90 rows × 39 columns
In [ ]:
# Define the columns to normalize
columns_to_normalize = [
'OP_distance', 'OP_distance_from_max', 'CO_distance', 'CO_distance_from_max',
'EX_distance', 'EX_distance_from_max', 'AG_distance', 'AG_distance_from_max',
'total_distance', 'average_distance'
]
# Create a new DataFrame with normalized columns
merged_df_norm = merged_df.copy()
# Normalize the specified columns
for column in columns_to_normalize:
merged_df_norm[column] = (merged_df_norm[column] - merged_df_norm[column].min()) / (merged_df_norm[column].max() - merged_df_norm[column].min())
merged_df_norm[columns_to_normalize].hist(figsize= (12,10))
Out[ ]:
array([[<Axes: title={'center': 'OP_distance'}>,
<Axes: title={'center': 'OP_distance_from_max'}>,
<Axes: title={'center': 'CO_distance'}>],
[<Axes: title={'center': 'CO_distance_from_max'}>,
<Axes: title={'center': 'EX_distance'}>,
<Axes: title={'center': 'EX_distance_from_max'}>],
[<Axes: title={'center': 'AG_distance'}>,
<Axes: title={'center': 'AG_distance_from_max'}>,
<Axes: title={'center': 'total_distance'}>],
[<Axes: title={'center': 'average_distance'}>, <Axes: >, <Axes: >]],
dtype=object)
In [ ]:
# Extract rows where both 'EX_distance_from_max' and 'average_distance' are <= 0.7
filtered_df = merged_df_norm[(merged_df_norm['EX_distance_from_max'] <= 0.7) & (merged_df_norm['average_distance'] <= 0.6)]
# Optional: Calculate the percentage of rows meeting the condition
percentage = (len(filtered_df) / len(merged_df_norm)) * 100
print(f"Percentage of rows meeting the condition: {percentage:.2f}%")
Percentage of rows meeting the condition: 70.00%
In [ ]:
import pandas as pd
import numpy as np
import statsmodels.api as sm
import statsmodels.formula.api as smf
from scipy import stats
from sklearn.preprocessing import StandardScaler
from statsmodels.stats.outliers_influence import variance_inflation_factor
import matplotlib.pyplot as plt
data = merged_df
# ResponseIdを文字列に変換
data['ResponseId'] = data['ResponseId'].astype(str)
# データの前処理
traits = ['EX', 'OP', 'CO', 'AG']
for trait in traits:
data[f'{trait}_distance_from_max_scaled'] = StandardScaler().fit_transform(data[[f'{trait}_distance_from_max']])
data['average_distance_scaled'] = StandardScaler().fit_transform(data[['average_distance']])
# 混合効果モデルの構築
def run_mixed_model(data, trait):
ad_preference = f'Ads_{trait}_1'
formula = (f"{ad_preference} ~ {trait}_distance_from_max_scaled + average_distance_scaled + "
f"{trait}_distance_from_max_scaled:average_distance_scaled")
model = smf.mixedlm(formula, data, groups=data['ResponseId'])
results = model.fit()
print(f"\nMixed Effects Model Results for {trait}:")
print(results.summary())
return results
# 効果分析
def analyze_effects(results, data, trait):
trait_effect = results.params[f'{trait}_distance_from_max_scaled']
avg_distance_effect = results.params['average_distance_scaled']
interaction_effect = results.params[f'{trait}_distance_from_max_scaled:average_distance_scaled']
print(f"\nEffect Analysis for {trait}:")
print(f"Effect of {trait} distance from max: {trait_effect}")
print(f"Effect of average distance: {avg_distance_effect}")
print(f"Interaction effect: {interaction_effect}")
# 統計的検定
for effect in [f'{trait}_distance_from_max_scaled', 'average_distance_scaled', f'{trait}_distance_from_max_scaled:average_distance_scaled']:
t_stat = results.tvalues[effect]
p_value = results.pvalues[effect]
print(f"\n{effect}:")
print(f"T-statistic: {t_stat}")
print(f"P-value: {p_value}")
# メインの分析ループ
for trait in traits:
# 混合効果モデル
results = run_mixed_model(data, trait)
# 効果分析
analyze_effects(results, data, trait)
# 多重共線性のチェック
X = sm.add_constant(data[[f'{trait}_distance_from_max_scaled', 'average_distance_scaled']])
vif = pd.DataFrame()
vif["features"] = X.columns
vif["VIF"] = [variance_inflation_factor(X.values, i) for i in range(X.shape[1])]
print("\nVIF:\n", vif)
# モデル診断(残差プロット)
plt.figure(figsize=(10, 6))
plt.scatter(results.fittedvalues, results.resid)
plt.xlabel('Fitted values')
plt.ylabel('Residuals')
plt.title(f'Residual Plot for {trait}')
plt.show()
# 頑健性チェック(ブートストラップ)
# Bootstrap manually since MixedLMResults does not have a bootstrap method
"""
bootstrapped_params = []
for _ in range(100):
sample_indices = np.random.choice(data.index, size=len(data), replace=True)
sample_data = data.loc[sample_indices]
sample_results = run_mixed_model(sample_data, trait)
bootstrapped_params.append(sample_results.params)
bootstrapped_params_df = pd.DataFrame(bootstrapped_params)
print("\nBootstrap Results:")
print(bootstrapped_params_df.describe())
"""
Mixed Effects Model Results for EX:
Mixed Linear Model Regression Results
===============================================================================================
Model: MixedLM Dependent Variable: Ads_EX_1
No. Observations: 90 Method: REML
No. Groups: 90 Scale: 515.1420
Min. group size: 1 Log-Likelihood: -429.2133
Max. group size: 1 Converged: Yes
Mean group size: 1.0
-----------------------------------------------------------------------------------------------
Coef. Std.Err. z P>|z| [0.025 0.975]
-----------------------------------------------------------------------------------------------
Intercept 53.719 3.210 16.733 0.000 47.427 60.011
EX_distance_from_max_scaled 9.237 3.399 2.717 0.007 2.575 15.899
average_distance_scaled 6.973 2.922 2.386 0.017 1.246 12.700
EX_distance_from_max_scaled:average_distance_scaled -2.614 1.744 -1.499 0.134 -6.033 0.805
Group Var 515.142
===============================================================================================
Effect Analysis for EX:
Effect of EX distance from max: 9.236731444764649
Effect of average distance: 6.9732976362044505
Interaction effect: -2.614142386564956
EX_distance_from_max_scaled:
T-statistic: 2.7174929666622285
P-value: 0.006577855342355496
average_distance_scaled:
T-statistic: 2.38647654804269
P-value: 0.01701069228185625
EX_distance_from_max_scaled:average_distance_scaled:
T-statistic: -1.4986328751579314
P-value: 0.1339688992290788
VIF:
features VIF
0 const 1.00000
1 EX_distance_from_max_scaled 1.02093
2 average_distance_scaled 1.02093
Mixed Effects Model Results for OP:
Mixed Linear Model Regression Results
===============================================================================================
Model: MixedLM Dependent Variable: Ads_OP_1
No. Observations: 90 Method: REML
No. Groups: 90 Scale: 491.0018
Min. group size: 1 Log-Likelihood: -427.1946
Max. group size: 1 Converged: Yes
Mean group size: 1.0
-----------------------------------------------------------------------------------------------
Coef. Std.Err. z P>|z| [0.025 0.975]
-----------------------------------------------------------------------------------------------
Intercept 42.394 3.382 12.535 0.000 35.765 49.023
OP_distance_from_max_scaled -0.653 2.575 -0.254 0.800 -5.701 4.395
average_distance_scaled 0.891 3.374 0.264 0.792 -5.722 7.503
OP_distance_from_max_scaled:average_distance_scaled 7.466 1.845 4.046 0.000 3.849 11.082
Group Var 491.002
===============================================================================================
Effect Analysis for OP:
Effect of OP distance from max: -0.6529035119332733
Effect of average distance: 0.8906779078620093
Interaction effect: 7.465531880451053
OP_distance_from_max_scaled:
T-statistic: -0.25351162272480904
P-value: 0.7998728808201359
average_distance_scaled:
T-statistic: 0.26399905395088863
P-value: 0.7917806477377052
OP_distance_from_max_scaled:average_distance_scaled:
T-statistic: 4.0463938172233815
P-value: 5.201270142719014e-05
VIF:
features VIF
0 const 1.000000
1 OP_distance_from_max_scaled 1.045077
2 average_distance_scaled 1.045077
Mixed Effects Model Results for CO:
Mixed Linear Model Regression Results
===============================================================================================
Model: MixedLM Dependent Variable: Ads_CO_1
No. Observations: 90 Method: REML
No. Groups: 90 Scale: 495.4618
Min. group size: 1 Log-Likelihood: -427.6217
Max. group size: 1 Converged: Yes
Mean group size: 1.0
-----------------------------------------------------------------------------------------------
Coef. Std.Err. z P>|z| [0.025 0.975]
-----------------------------------------------------------------------------------------------
Intercept 48.525 3.345 14.508 0.000 41.969 55.080
CO_distance_from_max_scaled 3.057 2.611 1.171 0.242 -2.060 8.174
average_distance_scaled 0.034 3.226 0.010 0.992 -6.289 6.357
CO_distance_from_max_scaled:average_distance_scaled -2.201 1.338 -1.645 0.100 -4.824 0.422
Group Var 495.462
===============================================================================================
Effect Analysis for CO:
Effect of CO distance from max: 3.057025850576481
Effect of average distance: 0.03356030426577199
Interaction effect: -2.2009905912533494
CO_distance_from_max_scaled:
T-statistic: 1.1708466648544527
P-value: 0.24166041671594096
average_distance_scaled:
T-statistic: 0.010402735306400398
P-value: 0.9916999678098024
CO_distance_from_max_scaled:average_distance_scaled:
T-statistic: -1.644863714962938
P-value: 0.09999791915021902
VIF:
features VIF
0 const 1.000000
1 CO_distance_from_max_scaled 1.028957
2 average_distance_scaled 1.028957
Mixed Effects Model Results for AG:
Mixed Linear Model Regression Results
===============================================================================================
Model: MixedLM Dependent Variable: Ads_AG_1
No. Observations: 90 Method: REML
No. Groups: 90 Scale: 358.9548
Min. group size: 1 Log-Likelihood: -413.8725
Max. group size: 1 Converged: Yes
Mean group size: 1.0
-----------------------------------------------------------------------------------------------
Coef. Std.Err. z P>|z| [0.025 0.975]
-----------------------------------------------------------------------------------------------
Intercept 59.208 2.399 24.682 0.000 54.507 63.910
AG_distance_from_max_scaled -0.496 3.097 -0.160 0.873 -6.567 5.574
average_distance_scaled 0.930 2.887 0.322 0.747 -4.729 6.589
AG_distance_from_max_scaled:average_distance_scaled 0.290 1.812 0.160 0.873 -3.262 3.842
Group Var 358.955
===============================================================================================
Effect Analysis for AG:
Effect of AG distance from max: -0.496349475215326
Effect of average distance: 0.9300928988487126
Interaction effect: 0.2900427887798393
AG_distance_from_max_scaled:
T-statistic: -0.16025380699059646
P-value: 0.8726811451916974
average_distance_scaled:
T-statistic: 0.3221343180987998
P-value: 0.747350940744358
AG_distance_from_max_scaled:average_distance_scaled:
T-statistic: 0.16004444586776856
P-value: 0.8728460626994023
VIF:
features VIF
0 const 1.000000
1 AG_distance_from_max_scaled 1.041976
2 average_distance_scaled 1.041976
sandbox for analysis methods¶
In [ ]:
merged_df
Out[ ]:
| ResponseId | OP_distance | OP_distance_from_max | CO_distance | CO_distance_from_max | EX_distance | EX_distance_from_max | AG_distance | AG_distance_from_max | total_distance | average_distance | Ads_OP_1 | Ads_OP_2 | Ads_OP_3 | Ads_OP_4 | Ads_OP_5 | Ads_OP_6 | Ads_CO_1 | Ads_CO_2 | Ads_CO_3 | Ads_CO_4 | Ads_CO_5 | Ads_CO_6 | Ads_EX_1 | Ads_EX_2 | Ads_EX_3 | Ads_EX_4 | Ads_EX_5 | Ads_EX_6 | Ads_AG_1 | Ads_AG_2 | Ads_AG_3 | Ads_AG_4 | Ads_AG_5 | Ads_AG_6 | Desc_OP_1 | Desc_CO_1 | Desc_EX_1 | Desc_AG_1 | EX_distance_from_max_scaled | OP_distance_from_max_scaled | CO_distance_from_max_scaled | AG_distance_from_max_scaled | average_distance_scaled | |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 0 | 641357b26802e397b5627d5e | 0.333333 | 0.833333 | 0.166667 | 0.833333 | 0.666667 | 1.166667 | 0.833333 | 1.833333 | 2.000000 | 0.500000 | 89 | 75 | 89 | 84 | 71 | 75 | 81 | 66 | 74 | 77 | 79 | 82 | 72 | 68 | 67 | 68 | 76 | 69 | 71 | 78 | 70 | 68 | 85 | 84 | 63 | 50 | 53 | 50 | -0.881537 | -0.550930 | -0.277944 | 1.076488 | -0.484285 |
| 1 | 66294a585f1cf3fdaeb80120 | 0.666667 | 1.833333 | 0.666667 | 0.333333 | 1.000000 | 0.833333 | 0.833333 | 1.833333 | 3.166667 | 0.791667 | 72 | 50 | 53 | 28 | 50 | 59 | 34 | 50 | 50 | 59 | 46 | 21 | 54 | 50 | 42 | 38 | 45 | 62 | 56 | 50 | 55 | 64 | 58 | 60 | 91 | 10 | 80 | 60 | -1.271406 | 0.820048 | -0.954025 | 1.076488 | 0.702872 |
| 2 | 661571d6cc16ee34676734df | 0.333333 | 0.833333 | 1.000000 | 2.000000 | 0.000000 | 1.833333 | 0.666667 | 1.666667 | 2.000000 | 0.500000 | 29 | 49 | 37 | 45 | 34 | 31 | 60 | 60 | 58 | 59 | 62 | 80 | 61 | 100 | 56 | 57 | 61 | 67 | 65 | 59 | 59 | 59 | 65 | 71 | 28 | 49 | 57 | 57 | -0.101799 | -0.550930 | 1.299577 | 0.837857 | -0.484285 |
| 3 | 6629f95a14b6006e6a4b0aef | 0.333333 | 0.833333 | 0.500000 | 1.500000 | 0.166667 | 2.000000 | 0.333333 | 0.666667 | 1.333333 | 0.333333 | 37 | 37 | 40 | 42 | 40 | 41 | 64 | 66 | 71 | 60 | 66 | 66 | 33 | 34 | 38 | 35 | 36 | 35 | 64 | 62 | 59 | 60 | 62 | 66 | 68 | 62 | 65 | 36 | 0.093135 | -0.550930 | 0.623496 | -0.593924 | -1.162660 |
| 4 | 66463d8b1984a328f78252d7 | 1.166667 | 0.000000 | 1.666667 | 2.666667 | 0.000000 | 1.833333 | 0.333333 | 1.333333 | 3.166667 | 0.791667 | 13 | 39 | 33 | 23 | 40 | 15 | 81 | 73 | 77 | 85 | 61 | 84 | 16 | 21 | 20 | 30 | 14 | 26 | 20 | 40 | 8 | 28 | 18 | 16 | 14 | 94 | 65 | 9 | -0.101799 | -1.693412 | 2.201018 | 0.360597 | 0.702872 |
| ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... |
| 85 | 5d4a6459061e2a000138bad3 | 1.166667 | 0.000000 | 0.666667 | 0.333333 | 0.500000 | 1.333333 | 0.333333 | 0.666667 | 2.666667 | 0.666667 | 48 | 73 | 48 | 48 | 48 | 47 | 11 | 40 | 10 | 10 | 9 | 10 | 93 | 52 | 96 | 95 | 95 | 95 | 14 | 80 | 14 | 46 | 17 | 44 | 7 | 26 | 54 | 47 | -0.686603 | -1.693412 | -0.954025 | -0.593924 | 0.194091 |
| 86 | 62b473736986d2b27c1427d2 | 1.166667 | 2.333333 | 0.333333 | 1.333333 | 1.000000 | 0.833333 | 0.500000 | 1.500000 | 3.000000 | 0.750000 | 72 | 27 | 27 | 40 | 17 | 30 | 71 | 88 | 26 | 26 | 68 | 82 | 33 | 15 | 76 | 30 | 70 | 13 | 74 | 26 | 66 | 25 | 68 | 45 | 21 | 28 | 84 | 68 | -1.271406 | 1.505537 | 0.398136 | 0.599227 | 0.533278 |
| 87 | 5f3ac1732efa0a74f975b1a8 | 0.833333 | 2.000000 | 0.333333 | 0.666667 | 0.333333 | 1.500000 | 0.833333 | 0.166667 | 2.333333 | 0.583333 | 5 | 14 | 0 | 3 | 31 | 0 | 24 | 0 | 26 | 0 | 46 | 0 | 29 | 1 | 3 | 50 | 28 | 23 | 81 | 58 | 77 | 60 | 51 | 59 | 100 | 59 | 0 | 11 | -0.491668 | 1.048544 | -0.503304 | -1.309815 | -0.145097 |
| 88 | 6601b51675d287d6a62f11c4 | 0.833333 | 0.333333 | 0.333333 | 0.666667 | 0.500000 | 1.333333 | 0.833333 | 0.166667 | 2.500000 | 0.625000 | 18 | 44 | 19 | 23 | 20 | 24 | 33 | 45 | 34 | 40 | 39 | 35 | 18 | 40 | 17 | 17 | 20 | 22 | 71 | 83 | 79 | 75 | 82 | 89 | 45 | 44 | 83 | 57 | -0.686603 | -1.236419 | -0.503304 | -1.309815 | 0.024497 |
| 89 | 6658822c0f5b1367a1585ee1 | 0.666667 | 1.833333 | 1.000000 | 0.000000 | 1.333333 | 0.500000 | 0.666667 | 0.333333 | 3.666667 | 0.916667 | 40 | 50 | 40 | 40 | 40 | 40 | 80 | 80 | 80 | 85 | 90 | 90 | 90 | 50 | 90 | 80 | 100 | 90 | 60 | 70 | 60 | 50 | 70 | 70 | 40 | 70 | 60 | 70 | -1.661275 | 0.820048 | -1.404745 | -1.071185 | 1.211654 |
90 rows × 44 columns
In [ ]:
import pandas as pd
import numpy as np
import statsmodels.api as sm
import statsmodels.formula.api as smf
from scipy import stats
from sklearn.preprocessing import StandardScaler
from sklearn.mixture import GaussianMixture
import matplotlib.pyplot as plt
import seaborn as sns
data = merged_df
# a. 差分スコアを用いた分析
"""
この分析は、Blended Personality広告と特性特化広告の直接比較を可能にします。
正の差分スコアは、Blended Personality広告がより好まれることを示し、
特性からの距離や平均距離との関係を明らかにすることで、どのような条件下でBlended Personality広告が
より効果的かを理解するのに役立ちます。
"""
for trait in ['EX', 'OP', 'CO', 'AG']:
# Blended Personality広告の平均スコアを計算
blended_cols = [f'Ads_{trait}_{i}' for i in range(1, 7)]
data[f'{trait}_blended_score'] = data[blended_cols].mean(axis=1)
# 差分スコアの計算(Blended - Trait Specific)
data[f'{trait}_diff_score'] = data[f'{trait}_blended_score'] - data[f'Ads_{trait}_1']
def analyze_diff_score(trait):
model = smf.ols(f'{trait}_diff_score ~ {trait}_distance_from_max_scaled + average_distance_scaled', data=data)
results = model.fit()
print(f"\nResults for {trait}:")
print(results.summary())
for trait in ['EX', 'OP', 'CO', 'AG']:
analyze_diff_score(trait)
Results for EX:
OLS Regression Results
==============================================================================
Dep. Variable: EX_diff_score R-squared: 0.006
Model: OLS Adj. R-squared: -0.017
Method: Least Squares F-statistic: 0.2507
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.779
Time: 07:59:38 Log-Likelihood: -315.81
No. Observations: 90 AIC: 637.6
Df Residuals: 87 BIC: 645.1
Df Model: 2
Covariance Type: nonrobust
===============================================================================================
coef std err t P>|t| [0.025 0.975]
-----------------------------------------------------------------------------------------------
Intercept -0.9759 0.867 -1.126 0.263 -2.699 0.747
EX_distance_from_max_scaled -0.6202 0.876 -0.708 0.481 -2.361 1.121
average_distance_scaled 0.0862 0.876 0.098 0.922 -1.655 1.827
==============================================================================
Omnibus: 50.893 Durbin-Watson: 2.169
Prob(Omnibus): 0.000 Jarque-Bera (JB): 264.181
Skew: -1.674 Prob(JB): 4.30e-58
Kurtosis: 10.697 Cond. No. 1.16
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Results for OP:
OLS Regression Results
==============================================================================
Dep. Variable: OP_diff_score R-squared: 0.008
Model: OLS Adj. R-squared: -0.015
Method: Least Squares F-statistic: 0.3423
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.711
Time: 07:59:38 Log-Likelihood: -376.71
No. Observations: 90 AIC: 759.4
Df Residuals: 87 BIC: 766.9
Df Model: 2
Covariance Type: nonrobust
===============================================================================================
coef std err t P>|t| [0.025 0.975]
-----------------------------------------------------------------------------------------------
Intercept -0.9389 1.705 -0.551 0.583 -4.328 2.451
OP_distance_from_max_scaled -1.4241 1.743 -0.817 0.416 -4.889 2.041
average_distance_scaled 0.5196 1.743 0.298 0.766 -2.945 3.985
==============================================================================
Omnibus: 26.642 Durbin-Watson: 2.470
Prob(Omnibus): 0.000 Jarque-Bera (JB): 269.685
Skew: -0.254 Prob(JB): 2.75e-59
Kurtosis: 11.465 Cond. No. 1.23
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Results for CO:
OLS Regression Results
==============================================================================
Dep. Variable: CO_diff_score R-squared: 0.008
Model: OLS Adj. R-squared: -0.015
Method: Least Squares F-statistic: 0.3621
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.697
Time: 07:59:38 Log-Likelihood: -352.74
No. Observations: 90 AIC: 711.5
Df Residuals: 87 BIC: 719.0
Df Model: 2
Covariance Type: nonrobust
===============================================================================================
coef std err t P>|t| [0.025 0.975]
-----------------------------------------------------------------------------------------------
Intercept -0.5667 1.307 -0.434 0.666 -3.164 2.030
CO_distance_from_max_scaled -1.0147 1.325 -0.766 0.446 -3.649 1.620
average_distance_scaled 0.6560 1.325 0.495 0.622 -1.978 3.290
==============================================================================
Omnibus: 34.490 Durbin-Watson: 2.404
Prob(Omnibus): 0.000 Jarque-Bera (JB): 615.522
Skew: 0.359 Prob(JB): 2.19e-134
Kurtosis: 15.792 Cond. No. 1.18
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Results for AG:
OLS Regression Results
==============================================================================
Dep. Variable: AG_diff_score R-squared: 0.025
Model: OLS Adj. R-squared: 0.003
Method: Least Squares F-statistic: 1.130
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.328
Time: 07:59:38 Log-Likelihood: -327.21
No. Observations: 90 AIC: 660.4
Df Residuals: 87 BIC: 667.9
Df Model: 2
Covariance Type: nonrobust
===============================================================================================
coef std err t P>|t| [0.025 0.975]
-----------------------------------------------------------------------------------------------
Intercept -0.0574 0.984 -0.058 0.954 -2.013 1.898
AG_distance_from_max_scaled 0.3739 1.004 0.372 0.711 -1.622 2.370
average_distance_scaled -1.5083 1.004 -1.502 0.137 -3.505 0.488
==============================================================================
Omnibus: 73.644 Durbin-Watson: 2.038
Prob(Omnibus): 0.000 Jarque-Bera (JB): 592.569
Skew: -2.491 Prob(JB): 2.11e-129
Kurtosis: 14.541 Cond. No. 1.23
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
In [ ]:
"""
マルチレベルモデルは、個人内での広告タイプの効果と個人間での特性の効果を同時に分析します。
これにより、Blended Personality広告が全体的にどの程度好まれるか、
また特定の特性や条件下でどのように効果が変化するかを理解できます。
"""
# b. マルチレベルモデル
data_long = pd.melt(data,
id_vars=['ResponseId', 'EX_distance_from_max_scaled', 'OP_distance_from_max_scaled',
'CO_distance_from_max_scaled', 'AG_distance_from_max_scaled', 'average_distance_scaled'],
value_vars=[col for col in data.columns if col.startswith('Ads_') and col.endswith(('1', '2', '3', '4', '5', '6'))],
var_name='ad_type', value_name='preference_score')
data_long['is_blended'] = ~data_long['ad_type'].str.endswith('1')
data_long['trait'] = data_long['ad_type'].str.split('_').str[1]
data_long['question_type'] = data_long['ad_type'].str.split('_').str[2]
model = smf.mixedlm("preference_score ~ is_blended + trait + question_type + is_blended:trait + average_distance_scaled",
data=data_long, groups=data_long["ResponseId"])
results = model.fit()
print(results.summary())
Mixed Linear Model Regression Results
==============================================================================================
Model: MixedLM Dependent Variable: preference_score
No. Observations: 2160 Method: REML
No. Groups: 90 Scale: 703.6243
Min. group size: 24 Log-Likelihood: -10197.7585
Max. group size: 24 Converged: No
Mean group size: 24.0
----------------------------------------------------------------------------------------------
Coef. Std.Err. z P>|z| [0.025 0.975]
----------------------------------------------------------------------------------------------
Intercept 59.267 3.234 18.328 0.000 52.929 65.605
is_blended[T.True] 629.051 54478103.123 0.000 1.000 -106774491.016 106775749.117
trait[T.CO] -11.111 3.954 -2.810 0.005 -18.861 -3.361
trait[T.EX] -5.922 3.954 -1.498 0.134 -13.672 1.828
trait[T.OP] -15.322 3.954 -3.875 0.000 -23.072 -7.572
question_type[T.2] -627.599 54478103.123 -0.000 1.000 -106775747.666 106774492.467
question_type[T.3] -629.122 54478103.123 -0.000 1.000 -106775749.188 106774490.945
question_type[T.4] -630.369 54478103.123 -0.000 1.000 -106775750.435 106774489.698
question_type[T.5] -629.324 54478103.123 -0.000 1.000 -106775749.391 106774490.742
question_type[T.6] -629.183 54478103.123 -0.000 1.000 -106775749.249 106774490.884
is_blended[T.True]:trait[T.CO] -0.611 4.332 -0.141 0.888 -9.101 7.879
is_blended[T.True]:trait[T.EX] -1.102 4.332 -0.254 0.799 -9.592 7.388
is_blended[T.True]:trait[T.OP] -1.058 4.332 -0.244 0.807 -9.548 7.432
average_distance_scaled 2.150 1.722 1.249 0.212 -1.225 5.525
Group Var 237.516 1.897
==============================================================================================
In [ ]:
"""
潜在クラス分析は、回答者を類似した特性と広告選好を持つグループに分類します。
これにより、Blended Personality広告がどのようなタイプの人々により効果的であるかを
探索的に理解することができ、GPT-4の広告生成能力の強みと限界を明らかにするのに役立ちます。
"""
# c. 潜在クラス分析(ここではGaussian Mixture Modelを使用)
features = ['EX_distance_from_max_scaled', 'OP_distance_from_max_scaled',
'CO_distance_from_max_scaled', 'AG_distance_from_max_scaled',
'average_distance_scaled'] + [f'{trait}_diff_score' for trait in ['EX', 'OP', 'CO', 'AG']]
X = data[features]
X_scaled = StandardScaler().fit_transform(X)
# モデルの適合(クラス数は仮に3としています)
gmm = GaussianMixture(n_components=3, random_state=42)
data['cluster'] = gmm.fit_predict(X_scaled)
# クラスタごとの特徴を可視化
plt.figure(figsize=(12, 6))
sns.boxplot(x='cluster', y='value', hue='variable',
data=pd.melt(data[features + ['cluster']], id_vars='cluster'))
plt.title('Feature Distribution by Cluster')
plt.show()
In [ ]:
"""
閾値を用いた分析は、Blended Personality広告の効果が特定の条件下で
どのように変化するかを明らかにします。これは、GPT-4が生成する広告の
効果が、ターゲットとなる個人の特性プロファイルにどの程度依存するかを
理解するのに役立ちます。
"""
# d. 閾値を用いた分析
data['high_average_distance'] = data['average_distance_scaled'] > data['average_distance_scaled'].median()
for trait in ['EX', 'OP', 'CO', 'AG']:
t_stat, p_value = stats.ttest_ind(
data[data['high_average_distance']][f'{trait}_diff_score'],
data[~data['high_average_distance']][f'{trait}_diff_score']
)
print(f"\n{trait} - T-test for diff_score between high and low average_distance groups:")
print(f"T-statistic: {t_stat}, P-value: {p_value}")
EX - T-test for diff_score between high and low average_distance groups: T-statistic: -0.060950428225559815, P-value: 0.9515369015866464 OP - T-test for diff_score between high and low average_distance groups: T-statistic: -0.19554658783863332, P-value: 0.8454158847783683 CO - T-test for diff_score between high and low average_distance groups: T-statistic: 0.48716244673001935, P-value: 0.6273545341037027 AG - T-test for diff_score between high and low average_distance groups: T-statistic: -1.1120780933553684, P-value: 0.2691334656935769
In [ ]:
"""
非線形関係の分析は、特性からの距離や平均距離と広告の好みの間の複雑な関係を
捉えることができます。これにより、GPT-4が生成する広告の効果が
線形的に変化するのではなく、特定の閾値や範囲で急激に変化する可能性を
検討することができます。
"""
# e. 非線形関係の考慮
for trait in ['EX', 'OP', 'CO', 'AG']:
model = smf.ols(f'{trait}_diff_score ~ {trait}_distance_from_max_scaled + I({trait}_distance_from_max_scaled**2) + '
'average_distance_scaled + I(average_distance_scaled**2)', data=data)
results = model.fit()
print(f"\nNon-linear model results for {trait}:")
print(results.summary())
Non-linear model results for EX:
OLS Regression Results
==============================================================================
Dep. Variable: EX_diff_score R-squared: 0.033
Model: OLS Adj. R-squared: -0.012
Method: Least Squares F-statistic: 0.7303
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.574
Time: 07:59:45 Log-Likelihood: -314.55
No. Observations: 90 AIC: 639.1
Df Residuals: 85 BIC: 651.6
Df Model: 4
Covariance Type: nonrobust
=======================================================================================================
coef std err t P>|t| [0.025 0.975]
-------------------------------------------------------------------------------------------------------
Intercept 0.3164 1.432 0.221 0.826 -2.531 3.164
EX_distance_from_max_scaled -0.5842 0.887 -0.659 0.512 -2.348 1.180
I(EX_distance_from_max_scaled ** 2) -1.4240 0.922 -1.544 0.126 -3.258 0.410
average_distance_scaled 0.9824 1.095 0.897 0.372 -1.195 3.160
I(average_distance_scaled ** 2) 0.1316 0.678 0.194 0.847 -1.217 1.480
==============================================================================
Omnibus: 40.873 Durbin-Watson: 2.194
Prob(Omnibus): 0.000 Jarque-Bera (JB): 170.764
Skew: -1.353 Prob(JB): 8.30e-38
Kurtosis: 9.181 Cond. No. 4.33
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Non-linear model results for OP:
OLS Regression Results
==============================================================================
Dep. Variable: OP_diff_score R-squared: 0.029
Model: OLS Adj. R-squared: -0.016
Method: Least Squares F-statistic: 0.6415
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.634
Time: 07:59:45 Log-Likelihood: -375.72
No. Observations: 90 AIC: 761.4
Df Residuals: 85 BIC: 773.9
Df Model: 4
Covariance Type: nonrobust
=======================================================================================================
coef std err t P>|t| [0.025 0.975]
-------------------------------------------------------------------------------------------------------
Intercept 1.3075 2.425 0.539 0.591 -3.515 6.130
OP_distance_from_max_scaled -0.7876 1.850 -0.426 0.671 -4.467 2.892
I(OP_distance_from_max_scaled ** 2) -1.4370 1.234 -1.165 0.247 -3.890 1.016
average_distance_scaled 1.6995 1.948 0.872 0.385 -2.174 5.573
I(average_distance_scaled ** 2) -0.8095 1.328 -0.610 0.544 -3.449 1.830
==============================================================================
Omnibus: 27.763 Durbin-Watson: 2.471
Prob(Omnibus): 0.000 Jarque-Bera (JB): 279.596
Skew: -0.343 Prob(JB): 1.93e-61
Kurtosis: 11.607 Cond. No. 3.74
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Non-linear model results for CO:
OLS Regression Results
==============================================================================
Dep. Variable: CO_diff_score R-squared: 0.011
Model: OLS Adj. R-squared: -0.036
Method: Least Squares F-statistic: 0.2368
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.917
Time: 07:59:45 Log-Likelihood: -352.62
No. Observations: 90 AIC: 715.2
Df Residuals: 85 BIC: 727.7
Df Model: 4
Covariance Type: nonrobust
=======================================================================================================
coef std err t P>|t| [0.025 0.975]
-------------------------------------------------------------------------------------------------------
Intercept -0.2973 2.103 -0.141 0.888 -4.478 3.884
CO_distance_from_max_scaled -1.0020 1.441 -0.695 0.489 -3.868 1.864
I(CO_distance_from_max_scaled ** 2) 0.2177 1.346 0.162 0.872 -2.459 2.895
average_distance_scaled 0.7036 1.600 0.440 0.661 -2.477 3.884
I(average_distance_scaled ** 2) -0.4871 1.035 -0.471 0.639 -2.545 1.571
==============================================================================
Omnibus: 34.408 Durbin-Watson: 2.406
Prob(Omnibus): 0.000 Jarque-Bera (JB): 607.876
Skew: 0.361 Prob(JB): 1.00e-132
Kurtosis: 15.711 Cond. No. 4.26
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Non-linear model results for AG:
OLS Regression Results
==============================================================================
Dep. Variable: AG_diff_score R-squared: 0.026
Model: OLS Adj. R-squared: -0.020
Method: Least Squares F-statistic: 0.5576
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.694
Time: 07:59:45 Log-Likelihood: -327.20
No. Observations: 90 AIC: 664.4
Df Residuals: 85 BIC: 676.9
Df Model: 4
Covariance Type: nonrobust
=======================================================================================================
coef std err t P>|t| [0.025 0.975]
-------------------------------------------------------------------------------------------------------
Intercept -0.1085 1.499 -0.072 0.942 -3.090 2.873
AG_distance_from_max_scaled 0.3610 1.049 0.344 0.732 -1.725 2.447
I(AG_distance_from_max_scaled ** 2) -0.0640 0.986 -0.065 0.948 -2.025 1.897
average_distance_scaled -1.5156 1.145 -1.324 0.189 -3.792 0.761
I(average_distance_scaled ** 2) 0.1151 0.804 0.143 0.886 -1.483 1.713
==============================================================================
Omnibus: 73.405 Durbin-Watson: 2.043
Prob(Omnibus): 0.000 Jarque-Bera (JB): 584.951
Skew: -2.485 Prob(JB): 9.54e-128
Kurtosis: 14.458 Cond. No. 3.89
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
sandbox 2¶
In [ ]:
import pandas as pd
import numpy as np
import statsmodels.api as sm
import statsmodels.formula.api as smf
from scipy import stats
from sklearn.preprocessing import StandardScaler
from sklearn.cluster import KMeans
import matplotlib.pyplot as plt
import seaborn as sns
In [ ]:
# データの読み込み(既存のデータフレームを 'data' とします)
data = merged_df
# 1. 相対的選好スコアの作成
for trait in ['EX', 'OP', 'CO', 'AG']:
for i in range(1, 7):
data[f'{trait}_relative_score_{i}'] = data[f'Ads_{trait}_{i}'] - 50
In [ ]:
# 2. 特性別分析
def analyze_trait(trait):
for i in range(1, 7):
model = smf.ols(f'{trait}_relative_score_{i} ~ {trait}_distance_from_max_scaled + average_distance_scaled', data=data)
results = model.fit()
print(f"\nResults for {trait}, question {i}:")
print(results.summary())
for trait in ['EX', 'OP', 'CO', 'AG']:
analyze_trait(trait)
Results for EX, question 1:
OLS Regression Results
===============================================================================
Dep. Variable: EX_relative_score_1 R-squared: 0.103
Model: OLS Adj. R-squared: 0.082
Method: Least Squares F-statistic: 4.986
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.00891
Time: 07:59:45 Log-Likelihood: -438.09
No. Observations: 90 AIC: 882.2
Df Residuals: 87 BIC: 889.7
Df Model: 2
Covariance Type: nonrobust
===============================================================================================
coef std err t P>|t| [0.025 0.975]
-----------------------------------------------------------------------------------------------
Intercept 3.3444 3.373 0.992 0.324 -3.360 10.049
EX_distance_from_max_scaled 7.5517 3.408 2.216 0.029 0.778 14.326
average_distance_scaled 6.5080 3.408 1.910 0.059 -0.266 13.282
==============================================================================
Omnibus: 21.498 Durbin-Watson: 1.739
Prob(Omnibus): 0.000 Jarque-Bera (JB): 4.968
Skew: -0.102 Prob(JB): 0.0834
Kurtosis: 1.867 Cond. No. 1.16
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Results for EX, question 2:
OLS Regression Results
===============================================================================
Dep. Variable: EX_relative_score_2 R-squared: 0.110
Model: OLS Adj. R-squared: 0.090
Method: Least Squares F-statistic: 5.384
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.00624
Time: 07:59:45 Log-Likelihood: -428.58
No. Observations: 90 AIC: 863.2
Df Residuals: 87 BIC: 870.7
Df Model: 2
Covariance Type: nonrobust
===============================================================================================
coef std err t P>|t| [0.025 0.975]
-----------------------------------------------------------------------------------------------
Intercept 1.1111 3.035 0.366 0.715 -4.921 7.143
EX_distance_from_max_scaled 7.8445 3.066 2.558 0.012 1.750 13.939
average_distance_scaled 5.1130 3.066 1.668 0.099 -0.981 11.208
==============================================================================
Omnibus: 9.881 Durbin-Watson: 1.766
Prob(Omnibus): 0.007 Jarque-Bera (JB): 3.406
Skew: 0.022 Prob(JB): 0.182
Kurtosis: 2.048 Cond. No. 1.16
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Results for EX, question 3:
OLS Regression Results
===============================================================================
Dep. Variable: EX_relative_score_3 R-squared: 0.071
Model: OLS Adj. R-squared: 0.049
Method: Least Squares F-statistic: 3.312
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.0411
Time: 07:59:45 Log-Likelihood: -441.95
No. Observations: 90 AIC: 889.9
Df Residuals: 87 BIC: 897.4
Df Model: 2
Covariance Type: nonrobust
===============================================================================================
coef std err t P>|t| [0.025 0.975]
-----------------------------------------------------------------------------------------------
Intercept 2.7778 3.521 0.789 0.432 -4.220 9.776
EX_distance_from_max_scaled 4.2020 3.557 1.181 0.241 -2.869 11.273
average_distance_scaled 7.4486 3.557 2.094 0.039 0.378 14.519
==============================================================================
Omnibus: 66.369 Durbin-Watson: 1.782
Prob(Omnibus): 0.000 Jarque-Bera (JB): 7.181
Skew: -0.103 Prob(JB): 0.0276
Kurtosis: 1.632 Cond. No. 1.16
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Results for EX, question 4:
Results for EX, question 4:
OLS Regression Results
===============================================================================
Dep. Variable: EX_relative_score_4 R-squared: 0.096
Model: OLS Adj. R-squared: 0.075
Method: Least Squares F-statistic: 4.631
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.0123
Time: 07:59:45 Log-Likelihood: -435.15
No. Observations: 90 AIC: 876.3
Df Residuals: 87 BIC: 883.8
Df Model: 2
Covariance Type: nonrobust
===============================================================================================
coef std err t P>|t| [0.025 0.975]
-----------------------------------------------------------------------------------------------
Intercept 0.6222 3.264 0.191 0.849 -5.866 7.111
EX_distance_from_max_scaled 7.0139 3.298 2.126 0.036 0.458 13.570
average_distance_scaled 6.1038 3.298 1.850 0.068 -0.452 12.660
==============================================================================
Omnibus: 25.099 Durbin-Watson: 1.671
Prob(Omnibus): 0.000 Jarque-Bera (JB): 5.164
Skew: 0.047 Prob(JB): 0.0756
Kurtosis: 1.830 Cond. No. 1.16
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Results for EX, question 5:
OLS Regression Results
===============================================================================
Dep. Variable: EX_relative_score_5 R-squared: 0.114
Model: OLS Adj. R-squared: 0.094
Method: Least Squares F-statistic: 5.592
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.00519
Time: 07:59:45 Log-Likelihood: -439.57
No. Observations: 90 AIC: 885.1
Df Residuals: 87 BIC: 892.6
Df Model: 2
Covariance Type: nonrobust
===============================================================================================
coef std err t P>|t| [0.025 0.975]
-----------------------------------------------------------------------------------------------
Intercept 3.3222 3.429 0.969 0.335 -3.493 10.137
EX_distance_from_max_scaled 6.9460 3.464 2.005 0.048 0.060 13.832
average_distance_scaled 8.1827 3.464 2.362 0.020 1.297 15.069
==============================================================================
Omnibus: 24.032 Durbin-Watson: 1.687
Prob(Omnibus): 0.000 Jarque-Bera (JB): 5.290
Skew: -0.133 Prob(JB): 0.0710
Kurtosis: 1.843 Cond. No. 1.16
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Results for EX, question 6:
OLS Regression Results
===============================================================================
Dep. Variable: EX_relative_score_6 R-squared: 0.096
Model: OLS Adj. R-squared: 0.075
Method: Least Squares F-statistic: 4.612
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.0125
Time: 07:59:45 Log-Likelihood: -443.11
No. Observations: 90 AIC: 892.2
Df Residuals: 87 BIC: 899.7
Df Model: 2
Covariance Type: nonrobust
===============================================================================================
coef std err t P>|t| [0.025 0.975]
-----------------------------------------------------------------------------------------------
Intercept 3.0333 3.567 0.850 0.397 -4.056 10.122
EX_distance_from_max_scaled 8.0312 3.604 2.229 0.028 0.868 15.194
average_distance_scaled 6.2094 3.604 1.723 0.088 -0.953 13.372
==============================================================================
Omnibus: 27.502 Durbin-Watson: 1.736
Prob(Omnibus): 0.000 Jarque-Bera (JB): 5.457
Skew: -0.101 Prob(JB): 0.0653
Kurtosis: 1.811 Cond. No. 1.16
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Results for OP, question 1:
OLS Regression Results
===============================================================================
Dep. Variable: OP_relative_score_1 R-squared: 0.022
Model: OLS Adj. R-squared: -0.001
Method: Least Squares F-statistic: 0.9581
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.388
Time: 07:59:45 Log-Likelihood: -437.98
No. Observations: 90 AIC: 882.0
Df Residuals: 87 BIC: 889.5
Df Model: 2
Covariance Type: nonrobust
===============================================================================================
coef std err t P>|t| [0.025 0.975]
-----------------------------------------------------------------------------------------------
Intercept -6.0556 3.369 -1.798 0.076 -12.751 0.640
OP_distance_from_max_scaled 4.6903 3.444 1.362 0.177 -2.155 11.535
average_distance_scaled -0.1388 3.444 -0.040 0.968 -6.984 6.706
==============================================================================
Omnibus: 38.063 Durbin-Watson: 1.888
Prob(Omnibus): 0.000 Jarque-Bera (JB): 6.967
Skew: 0.267 Prob(JB): 0.0307
Kurtosis: 1.746 Cond. No. 1.23
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Results for OP, question 2:
OLS Regression Results
===============================================================================
Dep. Variable: OP_relative_score_2 R-squared: 0.007
Model: OLS Adj. R-squared: -0.016
Method: Least Squares F-statistic: 0.2889
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.750
Time: 07:59:45 Log-Likelihood: -421.82
No. Observations: 90 AIC: 849.6
Df Residuals: 87 BIC: 857.1
Df Model: 2
Covariance Type: nonrobust
===============================================================================================
coef std err t P>|t| [0.025 0.975]
-----------------------------------------------------------------------------------------------
Intercept -4.2111 2.815 -1.496 0.138 -9.806 1.384
OP_distance_from_max_scaled 2.1416 2.878 0.744 0.459 -3.578 7.862
average_distance_scaled -0.0090 2.878 -0.003 0.998 -5.729 5.711
==============================================================================
Omnibus: 3.824 Durbin-Watson: 2.223
Prob(Omnibus): 0.148 Jarque-Bera (JB): 2.089
Skew: 0.064 Prob(JB): 0.352
Kurtosis: 2.265 Cond. No. 1.23
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Results for OP, question 3:
OLS Regression Results
===============================================================================
Dep. Variable: OP_relative_score_3 R-squared: 0.008
Model: OLS Adj. R-squared: -0.015
Method: Least Squares F-statistic: 0.3331
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.718
Time: 07:59:45 Log-Likelihood: -440.33
No. Observations: 90 AIC: 886.7
Df Residuals: 87 BIC: 894.2
Df Model: 2
Covariance Type: nonrobust
===============================================================================================
coef std err t P>|t| [0.025 0.975]
-----------------------------------------------------------------------------------------------
Intercept -6.9000 3.458 -1.995 0.049 -13.773 -0.027
OP_distance_from_max_scaled 2.8759 3.535 0.814 0.418 -4.151 9.902
average_distance_scaled -0.8247 3.535 -0.233 0.816 -7.851 6.202
==============================================================================
Omnibus: 46.816 Durbin-Watson: 1.936
Prob(Omnibus): 0.000 Jarque-Bera (JB): 7.457
Skew: 0.276 Prob(JB): 0.0240
Kurtosis: 1.702 Cond. No. 1.23
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Results for OP, question 4:
OLS Regression Results
===============================================================================
Dep. Variable: OP_relative_score_4 R-squared: 0.022
Model: OLS Adj. R-squared: -0.000
Method: Least Squares F-statistic: 0.9930
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.375
Time: 07:59:45 Log-Likelihood: -432.26
No. Observations: 90 AIC: 870.5
Df Residuals: 87 BIC: 878.0
Df Model: 2
Covariance Type: nonrobust
===============================================================================================
coef std err t P>|t| [0.025 0.975]
-----------------------------------------------------------------------------------------------
Intercept -8.5222 3.161 -2.696 0.008 -14.806 -2.239
OP_distance_from_max_scaled 3.8287 3.232 1.185 0.239 -2.595 10.252
average_distance_scaled 1.6172 3.232 0.500 0.618 -4.806 8.041
==============================================================================
Omnibus: 13.810 Durbin-Watson: 1.966
Prob(Omnibus): 0.001 Jarque-Bera (JB): 5.697
Skew: 0.367 Prob(JB): 0.0579
Kurtosis: 2.010 Cond. No. 1.23
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Results for OP, question 5:
OLS Regression Results
===============================================================================
Dep. Variable: OP_relative_score_5 R-squared: 0.010
Model: OLS Adj. R-squared: -0.013
Method: Least Squares F-statistic: 0.4416
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.644
Time: 07:59:45 Log-Likelihood: -435.37
No. Observations: 90 AIC: 876.7
Df Residuals: 87 BIC: 884.2
Df Model: 2
Covariance Type: nonrobust
===============================================================================================
coef std err t P>|t| [0.025 0.975]
-----------------------------------------------------------------------------------------------
Intercept -8.2333 3.273 -2.516 0.014 -14.738 -1.729
OP_distance_from_max_scaled 2.8814 3.345 0.861 0.391 -3.768 9.531
average_distance_scaled 0.6320 3.345 0.189 0.851 -6.017 7.281
==============================================================================
Omnibus: 17.137 Durbin-Watson: 2.016
Prob(Omnibus): 0.000 Jarque-Bera (JB): 6.616
Skew: 0.413 Prob(JB): 0.0366
Kurtosis: 1.959 Cond. No. 1.23
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Results for OP, question 6:
OLS Regression Results
===============================================================================
Dep. Variable: OP_relative_score_6 R-squared: 0.012
Model: OLS Adj. R-squared: -0.011
Method: Least Squares F-statistic: 0.5291
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.591
Time: 07:59:45 Log-Likelihood: -439.62
No. Observations: 90 AIC: 885.2
Df Residuals: 87 BIC: 892.7
Df Model: 2
Covariance Type: nonrobust
===============================================================================================
coef std err t P>|t| [0.025 0.975]
-----------------------------------------------------------------------------------------------
Intercept -8.0444 3.431 -2.345 0.021 -14.863 -1.226
OP_distance_from_max_scaled 3.1791 3.507 0.906 0.367 -3.792 10.150
average_distance_scaled 1.0082 3.507 0.287 0.774 -5.962 7.979
==============================================================================
Omnibus: 38.012 Durbin-Watson: 1.871
Prob(Omnibus): 0.000 Jarque-Bera (JB): 7.430
Skew: 0.323 Prob(JB): 0.0244
Kurtosis: 1.749 Cond. No. 1.23
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Results for CO, question 1:
OLS Regression Results
===============================================================================
Dep. Variable: CO_relative_score_1 R-squared: 0.003
Model: OLS Adj. R-squared: -0.020
Method: Least Squares F-statistic: 0.1193
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.888
Time: 07:59:45 Log-Likelihood: -436.31
No. Observations: 90 AIC: 878.6
Df Residuals: 87 BIC: 886.1
Df Model: 2
Covariance Type: nonrobust
===============================================================================================
coef std err t P>|t| [0.025 0.975]
-----------------------------------------------------------------------------------------------
Intercept -1.8444 3.307 -0.558 0.578 -8.417 4.728
CO_distance_from_max_scaled 1.6386 3.354 0.488 0.626 -5.029 8.306
average_distance_scaled -0.2937 3.354 -0.088 0.930 -6.961 6.374
==============================================================================
Omnibus: 40.136 Durbin-Watson: 2.122
Prob(Omnibus): 0.000 Jarque-Bera (JB): 6.125
Skew: 0.064 Prob(JB): 0.0468
Kurtosis: 1.728 Cond. No. 1.18
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Results for CO, question 2:
OLS Regression Results
===============================================================================
Dep. Variable: CO_relative_score_2 R-squared: 0.005
Model: OLS Adj. R-squared: -0.018
Method: Least Squares F-statistic: 0.1990
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.820
Time: 07:59:45 Log-Likelihood: -428.20
No. Observations: 90 AIC: 862.4
Df Residuals: 87 BIC: 869.9
Df Model: 2
Covariance Type: nonrobust
===============================================================================================
coef std err t P>|t| [0.025 0.975]
-----------------------------------------------------------------------------------------------
Intercept -0.8667 3.022 -0.287 0.775 -6.873 5.140
CO_distance_from_max_scaled -0.8477 3.065 -0.277 0.783 -6.940 5.245
average_distance_scaled -1.5712 3.065 -0.513 0.610 -7.664 4.521
==============================================================================
Omnibus: 6.127 Durbin-Watson: 2.068
Prob(Omnibus): 0.047 Jarque-Bera (JB): 2.687
Skew: 0.052 Prob(JB): 0.261
Kurtosis: 2.160 Cond. No. 1.18
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Results for CO, question 3:
OLS Regression Results
===============================================================================
Dep. Variable: CO_relative_score_3 R-squared: 0.002
Model: OLS Adj. R-squared: -0.021
Method: Least Squares F-statistic: 0.08013
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.923
Time: 07:59:45 Log-Likelihood: -439.72
No. Observations: 90 AIC: 885.4
Df Residuals: 87 BIC: 892.9
Df Model: 2
Covariance Type: nonrobust
===============================================================================================
coef std err t P>|t| [0.025 0.975]
-----------------------------------------------------------------------------------------------
Intercept -3.6444 3.435 -1.061 0.292 -10.471 3.182
CO_distance_from_max_scaled 0.3165 3.484 0.091 0.928 -6.608 7.241
average_distance_scaled 1.2860 3.484 0.369 0.713 -5.639 8.211
==============================================================================
Omnibus: 73.154 Durbin-Watson: 1.993
Prob(Omnibus): 0.000 Jarque-Bera (JB): 7.397
Skew: 0.115 Prob(JB): 0.0248
Kurtosis: 1.615 Cond. No. 1.18
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Results for CO, question 4:
OLS Regression Results
===============================================================================
Dep. Variable: CO_relative_score_4 R-squared: 0.003
Model: OLS Adj. R-squared: -0.020
Method: Least Squares F-statistic: 0.1242
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.883
Time: 07:59:45 Log-Likelihood: -434.09
No. Observations: 90 AIC: 874.2
Df Residuals: 87 BIC: 881.7
Df Model: 2
Covariance Type: nonrobust
===============================================================================================
coef std err t P>|t| [0.025 0.975]
-----------------------------------------------------------------------------------------------
Intercept -2.8444 3.226 -0.882 0.380 -9.257 3.568
CO_distance_from_max_scaled 0.4840 3.273 0.148 0.883 -6.021 6.989
average_distance_scaled 1.4546 3.273 0.444 0.658 -5.050 7.959
==============================================================================
Omnibus: 25.081 Durbin-Watson: 2.014
Prob(Omnibus): 0.000 Jarque-Bera (JB): 5.246
Skew: 0.091 Prob(JB): 0.0726
Kurtosis: 1.831 Cond. No. 1.18
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Results for CO, question 5:
OLS Regression Results
===============================================================================
Dep. Variable: CO_relative_score_5 R-squared: 0.003
Model: OLS Adj. R-squared: -0.020
Method: Least Squares F-statistic: 0.1145
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.892
Time: 07:59:45 Log-Likelihood: -438.00
No. Observations: 90 AIC: 882.0
Df Residuals: 87 BIC: 889.5
Df Model: 2
Covariance Type: nonrobust
===============================================================================================
coef std err t P>|t| [0.025 0.975]
-----------------------------------------------------------------------------------------------
Intercept -2.1556 3.370 -0.640 0.524 -8.853 4.542
CO_distance_from_max_scaled 0.8992 3.418 0.263 0.793 -5.895 7.693
average_distance_scaled 1.1964 3.418 0.350 0.727 -5.597 7.990
==============================================================================
Omnibus: 32.478 Durbin-Watson: 2.024
Prob(Omnibus): 0.000 Jarque-Bera (JB): 5.788
Skew: 0.100 Prob(JB): 0.0554
Kurtosis: 1.774 Cond. No. 1.18
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Results for CO, question 6:
OLS Regression Results
===============================================================================
Dep. Variable: CO_relative_score_6 R-squared: 0.001
Model: OLS Adj. R-squared: -0.022
Method: Least Squares F-statistic: 0.06073
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.941
Time: 07:59:45 Log-Likelihood: -445.36
No. Observations: 90 AIC: 896.7
Df Residuals: 87 BIC: 904.2
Df Model: 2
Covariance Type: nonrobust
===============================================================================================
coef std err t P>|t| [0.025 0.975]
-----------------------------------------------------------------------------------------------
Intercept -3.1111 3.657 -0.851 0.397 -10.379 4.157
CO_distance_from_max_scaled 1.2533 3.709 0.338 0.736 -6.119 8.626
average_distance_scaled 0.1017 3.709 0.027 0.978 -7.271 7.474
==============================================================================
Omnibus: 140.150 Durbin-Watson: 2.006
Prob(Omnibus): 0.000 Jarque-Bera (JB): 8.361
Skew: 0.089 Prob(JB): 0.0153
Kurtosis: 1.517 Cond. No. 1.18
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Results for AG, question 1:
OLS Regression Results
===============================================================================
Dep. Variable: AG_relative_score_1 R-squared: 0.001
Model: OLS Adj. R-squared: -0.022
Method: Least Squares F-statistic: 0.06090
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.941
Time: 07:59:45 Log-Likelihood: -421.60
No. Observations: 90 AIC: 849.2
Df Residuals: 87 BIC: 856.7
Df Model: 2
Covariance Type: nonrobust
===============================================================================================
coef std err t P>|t| [0.025 0.975]
-----------------------------------------------------------------------------------------------
Intercept 9.2667 2.808 3.300 0.001 3.685 14.848
AG_distance_from_max_scaled -0.3437 2.867 -0.120 0.905 -6.041 5.354
average_distance_scaled 0.9894 2.867 0.345 0.731 -4.708 6.687
==============================================================================
Omnibus: 5.821 Durbin-Watson: 1.892
Prob(Omnibus): 0.054 Jarque-Bera (JB): 5.091
Skew: -0.497 Prob(JB): 0.0784
Kurtosis: 2.394 Cond. No. 1.23
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Results for AG, question 2:
OLS Regression Results
===============================================================================
Dep. Variable: AG_relative_score_2 R-squared: 0.011
Model: OLS Adj. R-squared: -0.012
Method: Least Squares F-statistic: 0.4819
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.619
Time: 07:59:45 Log-Likelihood: -412.84
No. Observations: 90 AIC: 831.7
Df Residuals: 87 BIC: 839.2
Df Model: 2
Covariance Type: nonrobust
===============================================================================================
coef std err t P>|t| [0.025 0.975]
-----------------------------------------------------------------------------------------------
Intercept 11.7111 2.548 4.597 0.000 6.647 16.775
AG_distance_from_max_scaled -2.2699 2.601 -0.873 0.385 -7.439 2.899
average_distance_scaled -0.6897 2.601 -0.265 0.791 -5.859 4.479
==============================================================================
Omnibus: 3.126 Durbin-Watson: 1.855
Prob(Omnibus): 0.209 Jarque-Bera (JB): 3.118
Skew: -0.426 Prob(JB): 0.210
Kurtosis: 2.675 Cond. No. 1.23
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Results for AG, question 3:
OLS Regression Results
===============================================================================
Dep. Variable: AG_relative_score_3 R-squared: 0.003
Model: OLS Adj. R-squared: -0.020
Method: Least Squares F-statistic: 0.1328
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.876
Time: 07:59:45 Log-Likelihood: -426.72
No. Observations: 90 AIC: 859.4
Df Residuals: 87 BIC: 866.9
Df Model: 2
Covariance Type: nonrobust
===============================================================================================
coef std err t P>|t| [0.025 0.975]
-----------------------------------------------------------------------------------------------
Intercept 9.4222 2.973 3.170 0.002 3.514 15.331
AG_distance_from_max_scaled 0.0561 3.035 0.019 0.985 -5.975 6.088
average_distance_scaled -1.5423 3.035 -0.508 0.613 -7.574 4.489
==============================================================================
Omnibus: 6.489 Durbin-Watson: 1.944
Prob(Omnibus): 0.039 Jarque-Bera (JB): 4.136
Skew: -0.358 Prob(JB): 0.126
Kurtosis: 2.231 Cond. No. 1.23
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Results for AG, question 4:
OLS Regression Results
===============================================================================
Dep. Variable: AG_relative_score_4 R-squared: 0.001
Model: OLS Adj. R-squared: -0.022
Method: Least Squares F-statistic: 0.02770
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.973
Time: 07:59:45 Log-Likelihood: -420.08
No. Observations: 90 AIC: 846.2
Df Residuals: 87 BIC: 853.7
Df Model: 2
Covariance Type: nonrobust
===============================================================================================
coef std err t P>|t| [0.025 0.975]
-----------------------------------------------------------------------------------------------
Intercept 7.4111 2.761 2.684 0.009 1.923 12.899
AG_distance_from_max_scaled 0.6335 2.819 0.225 0.823 -4.969 6.236
average_distance_scaled 0.0657 2.819 0.023 0.981 -5.537 5.668
==============================================================================
Omnibus: 3.105 Durbin-Watson: 1.897
Prob(Omnibus): 0.212 Jarque-Bera (JB): 2.529
Skew: -0.287 Prob(JB): 0.282
Kurtosis: 2.412 Cond. No. 1.23
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Results for AG, question 5:
OLS Regression Results
===============================================================================
Dep. Variable: AG_relative_score_5 R-squared: 0.002
Model: OLS Adj. R-squared: -0.021
Method: Least Squares F-statistic: 0.1017
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.903
Time: 07:59:45 Log-Likelihood: -423.28
No. Observations: 90 AIC: 852.6
Df Residuals: 87 BIC: 860.1
Df Model: 2
Covariance Type: nonrobust
===============================================================================================
coef std err t P>|t| [0.025 0.975]
-----------------------------------------------------------------------------------------------
Intercept 7.9111 2.861 2.765 0.007 2.225 13.598
AG_distance_from_max_scaled 0.9945 2.920 0.341 0.734 -4.810 6.799
average_distance_scaled -1.0460 2.920 -0.358 0.721 -6.851 4.759
==============================================================================
Omnibus: 7.231 Durbin-Watson: 1.966
Prob(Omnibus): 0.027 Jarque-Bera (JB): 3.538
Skew: -0.237 Prob(JB): 0.171
Kurtosis: 2.152 Cond. No. 1.23
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Results for AG, question 6:
OLS Regression Results
===============================================================================
Dep. Variable: AG_relative_score_6 R-squared: 0.002
Model: OLS Adj. R-squared: -0.021
Method: Least Squares F-statistic: 0.08606
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.918
Time: 07:59:45 Log-Likelihood: -429.82
No. Observations: 90 AIC: 865.6
Df Residuals: 87 BIC: 873.1
Df Model: 2
Covariance Type: nonrobust
===============================================================================================
coef std err t P>|t| [0.025 0.975]
-----------------------------------------------------------------------------------------------
Intercept 9.5333 3.077 3.099 0.003 3.418 15.648
AG_distance_from_max_scaled 1.1107 3.141 0.354 0.724 -5.131 7.353
average_distance_scaled -0.8901 3.141 -0.283 0.778 -7.132 5.352
==============================================================================
Omnibus: 9.406 Durbin-Watson: 1.786
Prob(Omnibus): 0.009 Jarque-Bera (JB): 4.671
Skew: -0.337 Prob(JB): 0.0968
Kurtosis: 2.111 Cond. No. 1.23
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
In [ ]:
# 3. 多面的効果分析
effect_questions = {
'preference': 1,
'believability': 2,
'overall_liking': 3,
'persuasiveness': 4,
'interest': 5,
'click_likelihood': 6
}
def analyze_effect(effect):
question_num = effect_questions[effect]
for trait in ['EX', 'OP', 'CO', 'AG']:
model = smf.ols(f'{trait}_relative_score_{question_num} ~ average_distance_scaled', data=data)
results = model.fit()
print(f"\nResults for {effect} ({trait}):")
print(results.summary())
for effect in effect_questions.keys():
analyze_effect(effect)
Results for preference (EX):
OLS Regression Results
===============================================================================
Dep. Variable: EX_relative_score_1 R-squared: 0.052
Model: OLS Adj. R-squared: 0.041
Method: Least Squares F-statistic: 4.847
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.0303
Time: 07:59:45 Log-Likelihood: -440.57
No. Observations: 90 AIC: 885.1
Df Residuals: 88 BIC: 890.1
Df Model: 1
Covariance Type: nonrobust
===========================================================================================
coef std err t P>|t| [0.025 0.975]
-------------------------------------------------------------------------------------------
Intercept 3.3444 3.447 0.970 0.335 -3.506 10.195
average_distance_scaled 7.5893 3.447 2.202 0.030 0.739 14.440
==============================================================================
Omnibus: 58.365 Durbin-Watson: 1.767
Prob(Omnibus): 0.000 Jarque-Bera (JB): 7.043
Skew: -0.132 Prob(JB): 0.0296
Kurtosis: 1.655 Cond. No. 1.00
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Results for preference (OP):
OLS Regression Results
===============================================================================
Dep. Variable: OP_relative_score_1 R-squared: 0.001
Model: OLS Adj. R-squared: -0.011
Method: Least Squares F-statistic: 0.06089
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.806
Time: 07:59:45 Log-Likelihood: -438.93
No. Observations: 90 AIC: 881.9
Df Residuals: 88 BIC: 886.9
Df Model: 1
Covariance Type: nonrobust
===========================================================================================
coef std err t P>|t| [0.025 0.975]
-------------------------------------------------------------------------------------------
Intercept -6.0556 3.385 -1.789 0.077 -12.783 0.672
average_distance_scaled 0.8353 3.385 0.247 0.806 -5.892 7.563
==============================================================================
Omnibus: 53.483 Durbin-Watson: 1.935
Prob(Omnibus): 0.000 Jarque-Bera (JB): 7.467
Skew: 0.242 Prob(JB): 0.0239
Kurtosis: 1.674 Cond. No. 1.00
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Results for preference (CO):
OLS Regression Results
===============================================================================
Dep. Variable: CO_relative_score_1 R-squared: 0.000
Model: OLS Adj. R-squared: -0.011
Method: Least Squares F-statistic: 3.261e-05
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.995
Time: 07:59:45 Log-Likelihood: -436.44
No. Observations: 90 AIC: 876.9
Df Residuals: 88 BIC: 881.9
Df Model: 1
Covariance Type: nonrobust
===========================================================================================
coef std err t P>|t| [0.025 0.975]
-------------------------------------------------------------------------------------------
Intercept -1.8444 3.293 -0.560 0.577 -8.388 4.699
average_distance_scaled -0.0188 3.293 -0.006 0.995 -6.562 6.525
==============================================================================
Omnibus: 46.111 Durbin-Watson: 2.129
Prob(Omnibus): 0.000 Jarque-Bera (JB): 6.375
Skew: 0.050 Prob(JB): 0.0413
Kurtosis: 1.700 Cond. No. 1.00
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Results for preference (AG):
OLS Regression Results
===============================================================================
Dep. Variable: AG_relative_score_1 R-squared: 0.001
Model: OLS Adj. R-squared: -0.010
Method: Least Squares F-statistic: 0.1086
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.742
Time: 07:59:45 Log-Likelihood: -421.61
No. Observations: 90 AIC: 847.2
Df Residuals: 88 BIC: 852.2
Df Model: 1
Covariance Type: nonrobust
===========================================================================================
coef std err t P>|t| [0.025 0.975]
-------------------------------------------------------------------------------------------
Intercept 9.2667 2.792 3.318 0.001 3.717 14.816
average_distance_scaled 0.9205 2.792 0.330 0.742 -4.629 6.470
==============================================================================
Omnibus: 5.754 Durbin-Watson: 1.890
Prob(Omnibus): 0.056 Jarque-Bera (JB): 5.005
Skew: -0.491 Prob(JB): 0.0819
Kurtosis: 2.391 Cond. No. 1.00
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Results for believability (EX):
OLS Regression Results
===============================================================================
Dep. Variable: EX_relative_score_2 R-squared: 0.043
Model: OLS Adj. R-squared: 0.032
Method: Least Squares F-statistic: 3.973
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.0493
Time: 07:59:45 Log-Likelihood: -431.84
No. Observations: 90 AIC: 867.7
Df Residuals: 88 BIC: 872.7
Df Model: 1
Covariance Type: nonrobust
===========================================================================================
coef std err t P>|t| [0.025 0.975]
-------------------------------------------------------------------------------------------
Intercept 1.1111 3.129 0.355 0.723 -5.107 7.329
average_distance_scaled 6.2362 3.129 1.993 0.049 0.018 12.454
==============================================================================
Omnibus: 17.112 Durbin-Watson: 1.774
Prob(Omnibus): 0.000 Jarque-Bera (JB): 4.657
Skew: -0.143 Prob(JB): 0.0974
Kurtosis: 1.923 Cond. No. 1.00
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Results for believability (OP):
OLS Regression Results
===============================================================================
Dep. Variable: OP_relative_score_2 R-squared: 0.000
Model: OLS Adj. R-squared: -0.011
Method: Least Squares F-statistic: 0.02409
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.877
Time: 07:59:45 Log-Likelihood: -422.10
No. Observations: 90 AIC: 848.2
Df Residuals: 88 BIC: 853.2
Df Model: 1
Covariance Type: nonrobust
===========================================================================================
coef std err t P>|t| [0.025 0.975]
-------------------------------------------------------------------------------------------
Intercept -4.2111 2.808 -1.500 0.137 -9.791 1.369
average_distance_scaled 0.4358 2.808 0.155 0.877 -5.144 6.016
==============================================================================
Omnibus: 4.169 Durbin-Watson: 2.258
Prob(Omnibus): 0.124 Jarque-Bera (JB): 2.161
Skew: 0.031 Prob(JB): 0.339
Kurtosis: 2.243 Cond. No. 1.00
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Results for believability (CO):
OLS Regression Results
===============================================================================
Dep. Variable: CO_relative_score_2 R-squared: 0.004
Model: OLS Adj. R-squared: -0.008
Method: Least Squares F-statistic: 0.3249
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.570
Time: 07:59:45 Log-Likelihood: -428.24
No. Observations: 90 AIC: 860.5
Df Residuals: 88 BIC: 865.5
Df Model: 1
Covariance Type: nonrobust
===========================================================================================
coef std err t P>|t| [0.025 0.975]
-------------------------------------------------------------------------------------------
Intercept -0.8667 3.006 -0.288 0.774 -6.840 5.107
average_distance_scaled -1.7134 3.006 -0.570 0.570 -7.687 4.260
==============================================================================
Omnibus: 6.041 Durbin-Watson: 2.063
Prob(Omnibus): 0.049 Jarque-Bera (JB): 2.693
Skew: 0.071 Prob(JB): 0.260
Kurtosis: 2.165 Cond. No. 1.00
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Results for believability (AG):
OLS Regression Results
===============================================================================
Dep. Variable: AG_relative_score_2 R-squared: 0.002
Model: OLS Adj. R-squared: -0.009
Method: Least Squares F-statistic: 0.2026
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.654
Time: 07:59:45 Log-Likelihood: -413.23
No. Observations: 90 AIC: 830.5
Df Residuals: 88 BIC: 835.5
Df Model: 1
Covariance Type: nonrobust
===========================================================================================
coef std err t P>|t| [0.025 0.975]
-------------------------------------------------------------------------------------------
Intercept 11.7111 2.544 4.603 0.000 6.655 16.767
average_distance_scaled -1.1452 2.544 -0.450 0.654 -6.201 3.911
==============================================================================
Omnibus: 2.828 Durbin-Watson: 1.840
Prob(Omnibus): 0.243 Jarque-Bera (JB): 2.795
Skew: -0.386 Prob(JB): 0.247
Kurtosis: 2.613 Cond. No. 1.00
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Results for overall_liking (EX):
OLS Regression Results
===============================================================================
Dep. Variable: EX_relative_score_3 R-squared: 0.056
Model: OLS Adj. R-squared: 0.045
Method: Least Squares F-statistic: 5.205
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.0249
Time: 07:59:45 Log-Likelihood: -442.67
No. Observations: 90 AIC: 889.3
Df Residuals: 88 BIC: 894.3
Df Model: 1
Covariance Type: nonrobust
===========================================================================================
coef std err t P>|t| [0.025 0.975]
-------------------------------------------------------------------------------------------
Intercept 2.7778 3.529 0.787 0.433 -4.235 9.790
average_distance_scaled 8.0503 3.529 2.281 0.025 1.038 15.063
==============================================================================
Omnibus: 102.385 Durbin-Watson: 1.812
Prob(Omnibus): 0.000 Jarque-Bera (JB): 8.055
Skew: -0.138 Prob(JB): 0.0178
Kurtosis: 1.561 Cond. No. 1.00
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Results for overall_liking (OP):
OLS Regression Results
===============================================================================
Dep. Variable: OP_relative_score_3 R-squared: 0.000
Model: OLS Adj. R-squared: -0.011
Method: Least Squares F-statistic: 0.004343
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.948
Time: 07:59:45 Log-Likelihood: -440.68
No. Observations: 90 AIC: 885.4
Df Residuals: 88 BIC: 890.4
Df Model: 1
Covariance Type: nonrobust
===========================================================================================
coef std err t P>|t| [0.025 0.975]
-------------------------------------------------------------------------------------------
Intercept -6.9000 3.451 -1.999 0.049 -13.759 -0.041
average_distance_scaled -0.2274 3.451 -0.066 0.948 -7.086 6.632
==============================================================================
Omnibus: 53.076 Durbin-Watson: 1.962
Prob(Omnibus): 0.000 Jarque-Bera (JB): 7.521
Skew: 0.252 Prob(JB): 0.0233
Kurtosis: 1.676 Cond. No. 1.00
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Results for overall_liking (CO):
OLS Regression Results
===============================================================================
Dep. Variable: CO_relative_score_3 R-squared: 0.002
Model: OLS Adj. R-squared: -0.010
Method: Least Squares F-statistic: 0.1537
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.696
Time: 07:59:45 Log-Likelihood: -439.73
No. Observations: 90 AIC: 883.5
Df Residuals: 88 BIC: 888.5
Df Model: 1
Covariance Type: nonrobust
===========================================================================================
coef std err t P>|t| [0.025 0.975]
-------------------------------------------------------------------------------------------
Intercept -3.6444 3.415 -1.067 0.289 -10.431 3.143
average_distance_scaled 1.3391 3.415 0.392 0.696 -5.448 8.126
==============================================================================
Omnibus: 73.691 Durbin-Watson: 1.995
Prob(Omnibus): 0.000 Jarque-Bera (JB): 7.410
Skew: 0.115 Prob(JB): 0.0246
Kurtosis: 1.613 Cond. No. 1.00
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Results for overall_liking (AG):
OLS Regression Results
===============================================================================
Dep. Variable: AG_relative_score_3 R-squared: 0.003
Model: OLS Adj. R-squared: -0.008
Method: Least Squares F-statistic: 0.2683
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.606
Time: 07:59:45 Log-Likelihood: -426.73
No. Observations: 90 AIC: 857.5
Df Residuals: 88 BIC: 862.4
Df Model: 1
Covariance Type: nonrobust
===========================================================================================
coef std err t P>|t| [0.025 0.975]
-------------------------------------------------------------------------------------------
Intercept 9.4222 2.956 3.188 0.002 3.548 15.296
average_distance_scaled -1.5311 2.956 -0.518 0.606 -7.405 4.343
==============================================================================
Omnibus: 6.513 Durbin-Watson: 1.945
Prob(Omnibus): 0.039 Jarque-Bera (JB): 4.149
Skew: -0.359 Prob(JB): 0.126
Kurtosis: 2.231 Cond. No. 1.00
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Results for persuasiveness (EX):
OLS Regression Results
===============================================================================
Dep. Variable: EX_relative_score_4 R-squared: 0.049
Model: OLS Adj. R-squared: 0.038
Method: Least Squares F-statistic: 4.559
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.0355
Time: 07:59:45 Log-Likelihood: -437.43
No. Observations: 90 AIC: 878.9
Df Residuals: 88 BIC: 883.9
Df Model: 1
Covariance Type: nonrobust
===========================================================================================
coef std err t P>|t| [0.025 0.975]
-------------------------------------------------------------------------------------------
Intercept 0.6222 3.329 0.187 0.852 -5.994 7.238
average_distance_scaled 7.1080 3.329 2.135 0.036 0.492 13.724
==============================================================================
Omnibus: 51.766 Durbin-Watson: 1.705
Prob(Omnibus): 0.000 Jarque-Bera (JB): 6.638
Skew: -0.072 Prob(JB): 0.0362
Kurtosis: 1.677 Cond. No. 1.00
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Results for persuasiveness (OP):
OLS Regression Results
===============================================================================
Dep. Variable: OP_relative_score_4 R-squared: 0.007
Model: OLS Adj. R-squared: -0.005
Method: Least Squares F-statistic: 0.5797
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.448
Time: 07:59:45 Log-Likelihood: -432.98
No. Observations: 90 AIC: 870.0
Df Residuals: 88 BIC: 875.0
Df Model: 1
Covariance Type: nonrobust
===========================================================================================
coef std err t P>|t| [0.025 0.975]
-------------------------------------------------------------------------------------------
Intercept -8.5222 3.168 -2.690 0.009 -14.819 -2.226
average_distance_scaled 2.4124 3.168 0.761 0.448 -3.884 8.709
==============================================================================
Omnibus: 18.920 Durbin-Watson: 2.008
Prob(Omnibus): 0.000 Jarque-Bera (JB): 5.873
Skew: 0.312 Prob(JB): 0.0531
Kurtosis: 1.916 Cond. No. 1.00
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Results for persuasiveness (CO):
OLS Regression Results
===============================================================================
Dep. Variable: CO_relative_score_4 R-squared: 0.003
Model: OLS Adj. R-squared: -0.009
Method: Least Squares F-statistic: 0.2292
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.633
Time: 07:59:45 Log-Likelihood: -434.10
No. Observations: 90 AIC: 872.2
Df Residuals: 88 BIC: 877.2
Df Model: 1
Covariance Type: nonrobust
===========================================================================================
coef std err t P>|t| [0.025 0.975]
-------------------------------------------------------------------------------------------
Intercept -2.8444 3.208 -0.887 0.378 -9.220 3.531
average_distance_scaled 1.5358 3.208 0.479 0.633 -4.840 7.911
==============================================================================
Omnibus: 25.062 Durbin-Watson: 2.018
Prob(Omnibus): 0.000 Jarque-Bera (JB): 5.233
Skew: 0.086 Prob(JB): 0.0731
Kurtosis: 1.831 Cond. No. 1.00
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Results for persuasiveness (AG):
OLS Regression Results
===============================================================================
Dep. Variable: AG_relative_score_4 R-squared: 0.000
Model: OLS Adj. R-squared: -0.011
Method: Least Squares F-statistic: 0.004931
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.944
Time: 07:59:45 Log-Likelihood: -420.11
No. Observations: 90 AIC: 844.2
Df Residuals: 88 BIC: 849.2
Df Model: 1
Covariance Type: nonrobust
===========================================================================================
coef std err t P>|t| [0.025 0.975]
-------------------------------------------------------------------------------------------
Intercept 7.4111 2.746 2.699 0.008 1.953 12.869
average_distance_scaled 0.1929 2.746 0.070 0.944 -5.265 5.651
==============================================================================
Omnibus: 3.341 Durbin-Watson: 1.903
Prob(Omnibus): 0.188 Jarque-Bera (JB): 2.687
Skew: -0.299 Prob(JB): 0.261
Kurtosis: 2.400 Cond. No. 1.00
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Results for interest (EX):
OLS Regression Results
===============================================================================
Dep. Variable: EX_relative_score_5 R-squared: 0.073
Model: OLS Adj. R-squared: 0.062
Method: Least Squares F-statistic: 6.926
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.0100
Time: 07:59:45 Log-Likelihood: -441.60
No. Observations: 90 AIC: 887.2
Df Residuals: 88 BIC: 892.2
Df Model: 1
Covariance Type: nonrobust
===========================================================================================
coef std err t P>|t| [0.025 0.975]
-------------------------------------------------------------------------------------------
Intercept 3.3222 3.487 0.953 0.343 -3.608 10.252
average_distance_scaled 9.1773 3.487 2.632 0.010 2.247 16.107
==============================================================================
Omnibus: 65.588 Durbin-Watson: 1.726
Prob(Omnibus): 0.000 Jarque-Bera (JB): 7.624
Skew: -0.206 Prob(JB): 0.0221
Kurtosis: 1.635 Cond. No. 1.00
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Results for interest (OP):
OLS Regression Results
===============================================================================
Dep. Variable: OP_relative_score_5 R-squared: 0.002
Model: OLS Adj. R-squared: -0.010
Method: Least Squares F-statistic: 0.1418
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.707
Time: 07:59:45 Log-Likelihood: -435.75
No. Observations: 90 AIC: 875.5
Df Residuals: 88 BIC: 880.5
Df Model: 1
Covariance Type: nonrobust
===========================================================================================
coef std err t P>|t| [0.025 0.975]
-------------------------------------------------------------------------------------------
Intercept -8.2333 3.268 -2.520 0.014 -14.727 -1.739
average_distance_scaled 1.2304 3.268 0.377 0.707 -5.263 7.724
==============================================================================
Omnibus: 18.819 Durbin-Watson: 2.054
Prob(Omnibus): 0.000 Jarque-Bera (JB): 6.451
Skew: 0.377 Prob(JB): 0.0397
Kurtosis: 1.927 Cond. No. 1.00
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Results for interest (CO):
OLS Regression Results
===============================================================================
Dep. Variable: CO_relative_score_5 R-squared: 0.002
Model: OLS Adj. R-squared: -0.010
Method: Least Squares F-statistic: 0.1616
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.689
Time: 07:59:45 Log-Likelihood: -438.04
No. Observations: 90 AIC: 880.1
Df Residuals: 88 BIC: 885.1
Df Model: 1
Covariance Type: nonrobust
===========================================================================================
coef std err t P>|t| [0.025 0.975]
-------------------------------------------------------------------------------------------
Intercept -2.1556 3.352 -0.643 0.522 -8.816 4.505
average_distance_scaled 1.3473 3.352 0.402 0.689 -5.314 8.008
==============================================================================
Omnibus: 33.450 Durbin-Watson: 2.034
Prob(Omnibus): 0.000 Jarque-Bera (JB): 5.828
Skew: 0.093 Prob(JB): 0.0543
Kurtosis: 1.767 Cond. No. 1.00
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Results for interest (AG):
OLS Regression Results
===============================================================================
Dep. Variable: AG_relative_score_5 R-squared: 0.001
Model: OLS Adj. R-squared: -0.010
Method: Least Squares F-statistic: 0.08840
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.767
Time: 07:59:45 Log-Likelihood: -423.34
No. Observations: 90 AIC: 850.7
Df Residuals: 88 BIC: 855.7
Df Model: 1
Covariance Type: nonrobust
===========================================================================================
coef std err t P>|t| [0.025 0.975]
-------------------------------------------------------------------------------------------
Intercept 7.9111 2.847 2.779 0.007 2.254 13.568
average_distance_scaled -0.8464 2.847 -0.297 0.767 -6.503 4.811
==============================================================================
Omnibus: 7.366 Durbin-Watson: 1.975
Prob(Omnibus): 0.025 Jarque-Bera (JB): 3.727
Skew: -0.265 Prob(JB): 0.155
Kurtosis: 2.156 Cond. No. 1.00
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Results for click_likelihood (EX):
OLS Regression Results
===============================================================================
Dep. Variable: EX_relative_score_6 R-squared: 0.044
Model: OLS Adj. R-squared: 0.033
Method: Least Squares F-statistic: 4.074
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.0466
Time: 07:59:45 Log-Likelihood: -445.61
No. Observations: 90 AIC: 895.2
Df Residuals: 88 BIC: 900.2
Df Model: 1
Covariance Type: nonrobust
===========================================================================================
coef std err t P>|t| [0.025 0.975]
-------------------------------------------------------------------------------------------
Intercept 3.0333 3.646 0.832 0.408 -4.212 10.279
average_distance_scaled 7.3593 3.646 2.018 0.047 0.114 14.605
==============================================================================
Omnibus: 82.639 Durbin-Watson: 1.770
Prob(Omnibus): 0.000 Jarque-Bera (JB): 7.971
Skew: -0.194 Prob(JB): 0.0186
Kurtosis: 1.595 Cond. No. 1.00
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Results for click_likelihood (OP):
OLS Regression Results
===============================================================================
Dep. Variable: OP_relative_score_6 R-squared: 0.003
Model: OLS Adj. R-squared: -0.009
Method: Least Squares F-statistic: 0.2370
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.628
Time: 07:59:45 Log-Likelihood: -440.04
No. Observations: 90 AIC: 884.1
Df Residuals: 88 BIC: 889.1
Df Model: 1
Covariance Type: nonrobust
===========================================================================================
coef std err t P>|t| [0.025 0.975]
-------------------------------------------------------------------------------------------
Intercept -8.0444 3.427 -2.347 0.021 -14.855 -1.234
average_distance_scaled 1.6685 3.427 0.487 0.628 -5.142 8.479
==============================================================================
Omnibus: 50.413 Durbin-Watson: 1.909
Prob(Omnibus): 0.000 Jarque-Bera (JB): 7.635
Skew: 0.280 Prob(JB): 0.0220
Kurtosis: 1.687 Cond. No. 1.00
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Results for click_likelihood (CO):
OLS Regression Results
===============================================================================
Dep. Variable: CO_relative_score_6 R-squared: 0.000
Model: OLS Adj. R-squared: -0.011
Method: Least Squares F-statistic: 0.007353
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.932
Time: 07:59:45 Log-Likelihood: -445.42
No. Observations: 90 AIC: 894.8
Df Residuals: 88 BIC: 899.8
Df Model: 1
Covariance Type: nonrobust
===========================================================================================
coef std err t P>|t| [0.025 0.975]
-------------------------------------------------------------------------------------------
Intercept -3.1111 3.638 -0.855 0.395 -10.341 4.119
average_distance_scaled 0.3120 3.638 0.086 0.932 -6.918 7.542
==============================================================================
Omnibus: 158.113 Durbin-Watson: 2.020
Prob(Omnibus): 0.000 Jarque-Bera (JB): 8.490
Skew: 0.074 Prob(JB): 0.0143
Kurtosis: 1.503 Cond. No. 1.00
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Results for click_likelihood (AG):
OLS Regression Results
===============================================================================
Dep. Variable: AG_relative_score_6 R-squared: 0.001
Model: OLS Adj. R-squared: -0.011
Method: Least Squares F-statistic: 0.04750
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.828
Time: 07:59:45 Log-Likelihood: -429.88
No. Observations: 90 AIC: 863.8
Df Residuals: 88 BIC: 868.8
Df Model: 1
Covariance Type: nonrobust
===========================================================================================
coef std err t P>|t| [0.025 0.975]
-------------------------------------------------------------------------------------------
Intercept 9.5333 3.061 3.114 0.002 3.450 15.617
average_distance_scaled -0.6672 3.061 -0.218 0.828 -6.751 5.416
==============================================================================
Omnibus: 9.644 Durbin-Watson: 1.794
Prob(Omnibus): 0.008 Jarque-Bera (JB): 4.922
Skew: -0.362 Prob(JB): 0.0854
Kurtosis: 2.112 Cond. No. 1.00
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
In [ ]:
# 4. 距離の影響分析
for trait in ['EX', 'OP', 'CO', 'AG']:
data[f'{trait}_distance_diff'] = data[f'{trait}_distance_from_max'] - data[f'{trait}_distance']
def analyze_distances(trait):
model = smf.ols(f'{trait}_relative_score_1 ~ {trait}_distance + {trait}_distance_from_max + '
f'{trait}_distance_diff', data=data)
results = model.fit()
print(f"\nDistance analysis for {trait}:")
print(results.summary())
for trait in ['EX', 'OP', 'CO', 'AG']:
analyze_distances(trait)
Distance analysis for EX:
OLS Regression Results
===============================================================================
Dep. Variable: EX_relative_score_1 R-squared: 0.107
Model: OLS Adj. R-squared: 0.087
Method: Least Squares F-statistic: 5.235
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.00713
Time: 07:59:45 Log-Likelihood: -437.86
No. Observations: 90 AIC: 881.7
Df Residuals: 87 BIC: 889.2
Df Model: 2
Covariance Type: nonrobust
========================================================================================
coef std err t P>|t| [0.025 0.975]
----------------------------------------------------------------------------------------
Intercept -21.9229 8.821 -2.485 0.015 -39.456 -4.390
EX_distance 11.9212 4.446 2.682 0.009 3.085 20.757
EX_distance_from_max 10.0446 3.121 3.218 0.002 3.841 16.248
EX_distance_diff -1.8766 2.873 -0.653 0.515 -7.588 3.834
==============================================================================
Omnibus: 10.074 Durbin-Watson: 1.802
Prob(Omnibus): 0.006 Jarque-Bera (JB): 3.523
Skew: -0.086 Prob(JB): 0.172
Kurtosis: 2.046 Cond. No. 1.94e+16
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
[2] The smallest eigenvalue is 1.85e-30. This might indicate that there are
strong multicollinearity problems or that the design matrix is singular.
Distance analysis for OP:
OLS Regression Results
===============================================================================
Dep. Variable: OP_relative_score_1 R-squared: 0.022
Model: OLS Adj. R-squared: -0.001
Method: Least Squares F-statistic: 0.9588
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.387
Time: 07:59:45 Log-Likelihood: -437.98
No. Observations: 90 AIC: 882.0
Df Residuals: 87 BIC: 889.5
Df Model: 2
Covariance Type: nonrobust
========================================================================================
coef std err t P>|t| [0.025 0.975]
----------------------------------------------------------------------------------------
Intercept -14.0934 7.130 -1.977 0.051 -28.266 0.079
OP_distance 2.3980 5.134 0.467 0.642 -7.807 12.603
OP_distance_from_max 4.3457 3.451 1.259 0.211 -2.514 11.205
OP_distance_diff 1.9477 3.677 0.530 0.598 -5.361 9.257
==============================================================================
Omnibus: 37.534 Durbin-Watson: 1.885
Prob(Omnibus): 0.000 Jarque-Bera (JB): 6.940
Skew: 0.267 Prob(JB): 0.0311
Kurtosis: 1.749 Cond. No. 1.09e+16
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
[2] The smallest eigenvalue is 2.96e-30. This might indicate that there are
strong multicollinearity problems or that the design matrix is singular.
Distance analysis for CO:
OLS Regression Results
===============================================================================
Dep. Variable: CO_relative_score_1 R-squared: 0.012
Model: OLS Adj. R-squared: -0.010
Method: Least Squares F-statistic: 0.5435
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.583
Time: 07:59:46 Log-Likelihood: -435.88
No. Observations: 90 AIC: 877.8
Df Residuals: 87 BIC: 885.3
Df Model: 2
Covariance Type: nonrobust
========================================================================================
coef std err t P>|t| [0.025 0.975]
----------------------------------------------------------------------------------------
Intercept -7.2744 6.646 -1.094 0.277 -20.485 5.936
CO_distance 5.3361 5.215 1.023 0.309 -5.029 15.701
CO_distance_from_max 3.0448 3.442 0.885 0.379 -3.796 9.885
CO_distance_diff -2.2913 3.577 -0.641 0.523 -9.401 4.818
==============================================================================
Omnibus: 41.883 Durbin-Watson: 2.111
Prob(Omnibus): 0.000 Jarque-Bera (JB): 6.217
Skew: 0.068 Prob(JB): 0.0447
Kurtosis: 1.720 Cond. No. 1.09e+16
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
[2] The smallest eigenvalue is 2.43e-30. This might indicate that there are
strong multicollinearity problems or that the design matrix is singular.
Distance analysis for AG:
OLS Regression Results
===============================================================================
Dep. Variable: AG_relative_score_1 R-squared: 0.048
Model: OLS Adj. R-squared: 0.026
Method: Least Squares F-statistic: 2.202
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.117
Time: 07:59:46 Log-Likelihood: -419.44
No. Observations: 90 AIC: 844.9
Df Residuals: 87 BIC: 852.4
Df Model: 2
Covariance Type: nonrobust
========================================================================================
coef std err t P>|t| [0.025 0.975]
----------------------------------------------------------------------------------------
Intercept 3.4629 5.814 0.596 0.553 -8.092 15.018
AG_distance 9.3894 4.695 2.000 0.049 0.058 18.721
AG_distance_from_max 3.1495 3.050 1.032 0.305 -2.914 9.213
AG_distance_diff -6.2400 3.220 -1.938 0.056 -12.639 0.159
==============================================================================
Omnibus: 7.125 Durbin-Watson: 2.010
Prob(Omnibus): 0.028 Jarque-Bera (JB): 7.317
Skew: -0.697 Prob(JB): 0.0258
Kurtosis: 2.910 Cond. No. 1.58e+16
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
[2] The smallest eigenvalue is 1.18e-30. This might indicate that there are
strong multicollinearity problems or that the design matrix is singular.
Distance analysis for AG:
OLS Regression Results
===============================================================================
Dep. Variable: AG_relative_score_1 R-squared: 0.048
Model: OLS Adj. R-squared: 0.026
Method: Least Squares F-statistic: 2.202
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.117
Time: 07:59:46 Log-Likelihood: -419.44
No. Observations: 90 AIC: 844.9
Df Residuals: 87 BIC: 852.4
Df Model: 2
Covariance Type: nonrobust
========================================================================================
coef std err t P>|t| [0.025 0.975]
----------------------------------------------------------------------------------------
Intercept 3.4629 5.814 0.596 0.553 -8.092 15.018
AG_distance 9.3894 4.695 2.000 0.049 0.058 18.721
AG_distance_from_max 3.1495 3.050 1.032 0.305 -2.914 9.213
AG_distance_diff -6.2400 3.220 -1.938 0.056 -12.639 0.159
==============================================================================
Omnibus: 7.125 Durbin-Watson: 2.010
Prob(Omnibus): 0.028 Jarque-Bera (JB): 7.317
Skew: -0.697 Prob(JB): 0.0258
Kurtosis: 2.910 Cond. No. 1.58e+16
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
[2] The smallest eigenvalue is 1.18e-30. This might indicate that there are
strong multicollinearity problems or that the design matrix is singular.
In [ ]:
# 5. セグメント分析
def create_segments(trait):
kmeans = KMeans(n_clusters=3, random_state=42)
data[f'{trait}_segment'] = kmeans.fit_predict(data[[f'{trait}_distance_from_max_scaled', 'average_distance_scaled']])
for trait in ['EX', 'OP', 'CO', 'AG']:
create_segments(trait)
def analyze_segments(trait):
model = smf.ols(f'{trait}_relative_score_1 ~ C({trait}_segment)', data=data)
results = model.fit()
print(f"\nSegment analysis for {trait}:")
print(results.summary())
for trait in ['EX', 'OP', 'CO', 'AG']:
analyze_segments(trait)
Segment analysis for EX:
OLS Regression Results
===============================================================================
Dep. Variable: EX_relative_score_1 R-squared: 0.044
Model: OLS Adj. R-squared: 0.022
Method: Least Squares F-statistic: 1.980
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.144
Time: 07:59:50 Log-Likelihood: -440.97
No. Observations: 90 AIC: 887.9
Df Residuals: 87 BIC: 895.4
Df Model: 2
Covariance Type: nonrobust
======================================================================================
coef std err t P>|t| [0.025 0.975]
--------------------------------------------------------------------------------------
Intercept -0.4706 5.666 -0.083 0.934 -11.733 10.792
C(EX_segment)[T.1] 0.4436 7.849 0.057 0.955 -15.158 16.045
C(EX_segment)[T.2] 17.2074 9.464 1.818 0.072 -1.603 36.018
==============================================================================
Omnibus: 58.890 Durbin-Watson: 1.737
Prob(Omnibus): 0.000 Jarque-Bera (JB): 7.007
Skew: -0.118 Prob(JB): 0.0301
Kurtosis: 1.653 Cond. No. 3.67
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Segment analysis for OP:
OLS Regression Results
===============================================================================
Dep. Variable: OP_relative_score_1 R-squared: 0.032
Model: OLS Adj. R-squared: 0.010
Method: Least Squares F-statistic: 1.427
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.246
Time: 07:59:50 Log-Likelihood: -437.51
No. Observations: 90 AIC: 881.0
Df Residuals: 87 BIC: 888.5
Df Model: 2
Covariance Type: nonrobust
======================================================================================
coef std err t P>|t| [0.025 0.975]
--------------------------------------------------------------------------------------
Intercept 0.6333 5.804 0.109 0.913 -10.904 12.170
C(OP_segment)[T.1] -16.6333 10.054 -1.654 0.102 -36.616 3.349
C(OP_segment)[T.2] -7.8333 7.494 -1.045 0.299 -22.728 7.061
==============================================================================
Omnibus: 38.891 Durbin-Watson: 1.913
Prob(Omnibus): 0.000 Jarque-Bera (JB): 7.080
Skew: 0.276 Prob(JB): 0.0290
Kurtosis: 1.741 Cond. No. 4.05
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Segment analysis for CO:
OLS Regression Results
===============================================================================
Dep. Variable: CO_relative_score_1 R-squared: 0.012
Model: OLS Adj. R-squared: -0.011
Method: Least Squares F-statistic: 0.5109
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.602
Time: 07:59:50 Log-Likelihood: -435.91
No. Observations: 90 AIC: 877.8
Df Residuals: 87 BIC: 885.3
Df Model: 2
Covariance Type: nonrobust
======================================================================================
coef std err t P>|t| [0.025 0.975]
--------------------------------------------------------------------------------------
Intercept -0.1429 4.819 -0.030 0.976 -9.722 9.436
C(CO_segment)[T.1] -6.2905 7.466 -0.843 0.402 -21.130 8.549
C(CO_segment)[T.2] 1.9762 8.799 0.225 0.823 -15.512 19.465
==============================================================================
Omnibus: 33.743 Durbin-Watson: 2.117
Prob(Omnibus): 0.000 Jarque-Bera (JB): 5.828
Skew: 0.086 Prob(JB): 0.0543
Kurtosis: 1.765 Cond. No. 3.37
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Segment analysis for AG:
OLS Regression Results
===============================================================================
Dep. Variable: AG_relative_score_1 R-squared: 0.004
Model: OLS Adj. R-squared: -0.019
Method: Least Squares F-statistic: 0.1890
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.828
Time: 07:59:50 Log-Likelihood: -421.47
No. Observations: 90 AIC: 848.9
Df Residuals: 87 BIC: 856.4
Df Model: 2
Covariance Type: nonrobust
======================================================================================
coef std err t P>|t| [0.025 0.975]
--------------------------------------------------------------------------------------
Intercept 6.4545 5.672 1.138 0.258 -4.818 17.727
C(AG_segment)[T.1] 4.5799 7.521 0.609 0.544 -10.369 19.529
C(AG_segment)[T.2] 3.0839 7.093 0.435 0.665 -11.015 17.182
==============================================================================
Omnibus: 5.899 Durbin-Watson: 1.880
Prob(Omnibus): 0.052 Jarque-Bera (JB): 5.173
Skew: -0.503 Prob(JB): 0.0753
Kurtosis: 2.394 Cond. No. 4.33
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
In [ ]:
# 6. 交互作用効果の分析
def analyze_interactions(trait):
model = smf.ols(f'{trait}_relative_score_1 ~ {trait}_distance_from_max_scaled * average_distance_scaled', data=data)
results = model.fit()
print(f"\nInteraction analysis for {trait}:")
print(results.summary())
for trait in ['EX', 'OP', 'CO', 'AG']:
analyze_interactions(trait)
# 可視化
plt.figure(figsize=(12, 8))
for i, trait in enumerate(['EX', 'OP', 'CO', 'AG']):
plt.subplot(2, 2, i+1)
sns.scatterplot(x=f'{trait}_distance_from_max_scaled', y=f'{trait}_relative_score_1',
hue='average_distance_scaled', data=data)
plt.title(f'{trait} Analysis')
plt.tight_layout()
plt.show()
# 可視化2
plt.figure(figsize=(12, 8))
# 全てのTraitの中での最大値と最小値を計算
x_min = min(data[f'{trait}_distance_from_max'].min() for trait in ['EX', 'OP', 'CO', 'AG'])
x_max = max(data[f'{trait}_distance_from_max'].max() for trait in ['EX', 'OP', 'CO', 'AG'])
y_min = data['average_distance'].min()
y_max = data['average_distance'].max()
# マージンを追加
margin = 0.1
x_range = x_max - x_min
y_range = y_max - y_min
x_min -= margin * x_range
x_max += margin * x_range
y_min -= margin * y_range
y_max += margin * y_range
for i, trait in enumerate(['EX', 'OP', 'CO', 'AG']):
plt.subplot(2, 2, i+1)
scatter = plt.scatter(data[f'{trait}_distance_from_max'],
data['average_distance'],
c=data[f'{trait}_relative_score_1'],
cmap='coolwarm',
alpha=0.7)
plt.colorbar(scatter, label=f'Perceived_personalization_score')
plt.xlabel(f'{trait}_distance_from_max')
plt.ylabel('average_distance')
plt.title(f'{trait} Perceived Personalization Score Distribution')
# 全てのチャートで同じX軸とY軸の範囲を設定
plt.xlim(x_min, x_max)
plt.ylim(y_min, y_max)
plt.tight_layout()
plt.show()
# 可視化3
plt.figure(figsize=(12, 8))
# 全てのTraitの中での最大値と最小値を計算
x_min = min(data[f'{trait}_distance_from_max_scaled'].min() for trait in ['EX', 'OP', 'CO', 'AG'])
x_max = max(data[f'{trait}_distance_from_max_scaled'].max() for trait in ['EX', 'OP', 'CO', 'AG'])
y_min = data['average_distance_scaled'].min()
y_max = data['average_distance_scaled'].max()
# マージンを追加
margin = 0.1
x_range = x_max - x_min
y_range = y_max - y_min
x_min -= margin * x_range
x_max += margin * x_range
y_min -= margin * y_range
y_max += margin * y_range
for i, trait in enumerate(['EX', 'OP', 'CO', 'AG']):
plt.subplot(2, 2, i+1)
scatter = plt.scatter(data[f'{trait}_distance_from_max_scaled'],
data['average_distance_scaled'],
c=data[f'{trait}_relative_score_1'],
cmap='coolwarm',
alpha=0.7)
plt.colorbar(scatter, label=f'Perceived_personalization_score')
plt.xlabel(f'{trait}_distance_from_max_scaled')
plt.ylabel('average_distance_scaled')
plt.title(f'{trait} Perceived Personalization Score Distribution')
# 全てのチャートで同じX軸とY軸の範囲を設定
plt.xlim(x_min, x_max)
plt.ylim(y_min, y_max)
plt.tight_layout()
plt.show()
Interaction analysis for EX:
OLS Regression Results
===============================================================================
Dep. Variable: EX_relative_score_1 R-squared: 0.108
Model: OLS Adj. R-squared: 0.077
Method: Least Squares F-statistic: 3.460
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.0198
Time: 08:59:01 Log-Likelihood: -437.85
No. Observations: 90 AIC: 883.7
Df Residuals: 86 BIC: 893.7
Df Model: 3
Covariance Type: nonrobust
=======================================================================================================================
coef std err t P>|t| [0.025 0.975]
-----------------------------------------------------------------------------------------------------------------------
Intercept 3.7187 3.427 1.085 0.281 -3.095 10.532
EX_distance_from_max_scaled 9.2367 4.213 2.193 0.031 0.862 17.611
average_distance_scaled 6.9733 3.486 2.001 0.049 0.044 13.902
EX_distance_from_max_scaled:average_distance_scaled -2.6141 3.819 -0.685 0.495 -10.206 4.978
==============================================================================
Omnibus: 18.410 Durbin-Watson: 1.754
Prob(Omnibus): 0.000 Jarque-Bera (JB): 4.741
Skew: -0.127 Prob(JB): 0.0934
Kurtosis: 1.905 Cond. No. 2.11
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Interaction analysis for OP:
OLS Regression Results
===============================================================================
Dep. Variable: OP_relative_score_1 R-squared: 0.070
Model: OLS Adj. R-squared: 0.038
Method: Least Squares F-statistic: 2.162
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.0984
Time: 08:59:01 Log-Likelihood: -435.69
No. Observations: 90 AIC: 879.4
Df Residuals: 86 BIC: 889.4
Df Model: 3
Covariance Type: nonrobust
=======================================================================================================================
coef std err t P>|t| [0.025 0.975]
-----------------------------------------------------------------------------------------------------------------------
Intercept -7.6060 3.383 -2.248 0.027 -14.332 -0.880
OP_distance_from_max_scaled -0.6529 4.214 -0.155 0.877 -9.030 7.724
average_distance_scaled 0.8907 3.412 0.261 0.795 -5.891 7.673
OP_distance_from_max_scaled:average_distance_scaled 7.4655 3.522 2.119 0.037 0.463 14.468
==============================================================================
Omnibus: 42.283 Durbin-Watson: 1.871
Prob(Omnibus): 0.000 Jarque-Bera (JB): 6.957
Skew: 0.235 Prob(JB): 0.0308
Kurtosis: 1.722 Cond. No. 2.17
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Interaction analysis for CO:
OLS Regression Results
===============================================================================
Dep. Variable: CO_relative_score_1 R-squared: 0.007
Model: OLS Adj. R-squared: -0.027
Method: Least Squares F-statistic: 0.2161
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.885
Time: 08:59:01 Log-Likelihood: -436.10
No. Observations: 90 AIC: 880.2
Df Residuals: 86 BIC: 890.2
Df Model: 3
Covariance Type: nonrobust
=======================================================================================================================
coef std err t P>|t| [0.025 0.975]
-----------------------------------------------------------------------------------------------------------------------
Intercept -1.4752 3.368 -0.438 0.662 -8.170 5.220
CO_distance_from_max_scaled 3.0570 4.028 0.759 0.450 -4.949 11.064
average_distance_scaled 0.0336 3.404 0.010 0.992 -6.734 6.801
CO_distance_from_max_scaled:average_distance_scaled -2.2010 3.432 -0.641 0.523 -9.024 4.622
==============================================================================
Omnibus: 32.707 Durbin-Watson: 2.139
Prob(Omnibus): 0.000 Jarque-Bera (JB): 5.705
Skew: 0.056 Prob(JB): 0.0577
Kurtosis: 1.772 Cond. No. 2.03
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
Interaction analysis for AG:
OLS Regression Results
===============================================================================
Dep. Variable: AG_relative_score_1 R-squared: 0.002
Model: OLS Adj. R-squared: -0.033
Method: Least Squares F-statistic: 0.04428
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.988
Time: 08:59:01 Log-Likelihood: -421.59
No. Observations: 90 AIC: 851.2
Df Residuals: 86 BIC: 861.2
Df Model: 3
Covariance Type: nonrobust
=======================================================================================================================
coef std err t P>|t| [0.025 0.975]
-----------------------------------------------------------------------------------------------------------------------
Intercept 9.2085 2.872 3.206 0.002 3.499 14.918
AG_distance_from_max_scaled -0.4963 3.192 -0.156 0.877 -6.841 5.848
average_distance_scaled 0.9301 2.932 0.317 0.752 -4.898 6.758
AG_distance_from_max_scaled:average_distance_scaled 0.2900 2.602 0.111 0.912 -4.883 5.463
==============================================================================
Omnibus: 5.765 Durbin-Watson: 1.893
Prob(Omnibus): 0.056 Jarque-Bera (JB): 5.048
Skew: -0.495 Prob(JB): 0.0801
Kurtosis: 2.396 Cond. No. 1.83
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
In [ ]:
import numpy as np
import matplotlib.pyplot as plt
import seaborn as sns
from scipy import stats
import statsmodels.api as sm
from statsmodels.stats.multitest import multipletests
def analyze_trait(trait, data):
# 3x3のグリッドを作成
x_percentiles = np.percentile(data[f'{trait}_distance_from_max_scaled'], [33, 67])
y_percentiles = np.percentile(data['average_distance_scaled'], [33, 67])
# プロット
plt.figure(figsize=(10, 8))
scatter = plt.scatter(data[f'{trait}_distance_from_max_scaled'],
data['average_distance_scaled'],
c=data[f'{trait}_relative_score_1'],
cmap='coolwarm',
alpha=0.7)
plt.colorbar(scatter, label='Perceived personalization score')
plt.xlabel(f'{trait}_distance_from_max_scaled')
plt.ylabel('average_distance_scaled')
plt.title(f'{trait} Perceived Personalization Score Distribution')
# グリッドラインを追加
for x in x_percentiles:
plt.axvline(x, color='grey', linestyle='--', alpha=0.5)
for y in y_percentiles:
plt.axhline(y, color='grey', linestyle='--', alpha=0.5)
plt.tight_layout()
plt.show()
# セクションの定義
def get_section(x, y):
x_section = np.digitize(x, x_percentiles)
y_section = np.digitize(y, y_percentiles)
return y_section * 3 + x_section + 1
data['section'] = get_section(data[f'{trait}_distance_from_max_scaled'],
data['average_distance_scaled'])
# 回帰分析
X = sm.add_constant(data[[f'{trait}_distance_from_max_scaled', 'average_distance_scaled']])
X['interaction'] = data[f'{trait}_distance_from_max_scaled'] * data['average_distance_scaled']
y = data[f'{trait}_relative_score_1']
model = sm.OLS(y, X).fit()
print(model.summary())
# セクション間の比較
sections_to_compare = [1, 3, 7, 9] # 四隅のセクション
section_scores = [data[data['section'] == s][f'{trait}_relative_score_1'] for s in sections_to_compare]
# ANOVA
f_statistic, p_value = stats.f_oneway(*section_scores)
print(f"ANOVA results: F-statistic = {f_statistic}, p-value = {p_value}")
# ポストホック分析(Tukey's HSD)
from statsmodels.stats.multicomp import pairwise_tukeyhsd
scores_flat = np.concatenate(section_scores)
groups_flat = np.concatenate([[s] * len(scores) for s, scores in zip(sections_to_compare, section_scores)])
tukey_results = pairwise_tukeyhsd(scores_flat, groups_flat)
print(tukey_results)
# 多重比較の補正
_, corrected_p_values, _, _ = multipletests([pair[3] for pair in tukey_results._results_table.data[1:]],
method='fdr_bh')
print("Corrected p-values:", corrected_p_values)
# 各特性に対して分析を実行
for trait in ['EX', 'OP', 'CO', 'AG']:
analyze_trait(trait, data)
OLS Regression Results
===============================================================================
Dep. Variable: EX_relative_score_1 R-squared: 0.108
Model: OLS Adj. R-squared: 0.077
Method: Least Squares F-statistic: 3.460
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.0198
Time: 09:15:38 Log-Likelihood: -437.85
No. Observations: 90 AIC: 883.7
Df Residuals: 86 BIC: 893.7
Df Model: 3
Covariance Type: nonrobust
===============================================================================================
coef std err t P>|t| [0.025 0.975]
-----------------------------------------------------------------------------------------------
const 3.7187 3.427 1.085 0.281 -3.095 10.532
EX_distance_from_max_scaled 9.2367 4.213 2.193 0.031 0.862 17.611
average_distance_scaled 6.9733 3.486 2.001 0.049 0.044 13.902
interaction -2.6141 3.819 -0.685 0.495 -10.206 4.978
==============================================================================
Omnibus: 18.410 Durbin-Watson: 1.754
Prob(Omnibus): 0.000 Jarque-Bera (JB): 4.741
Skew: -0.127 Prob(JB): 0.0934
Kurtosis: 1.905 Cond. No. 2.11
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
ANOVA results: F-statistic = 1.0782167125833009, p-value = 0.3713577803810246
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
1 3 27.2222 0.564 -28.9627 83.4071 False
1 7 9.6333 0.9654 -45.8448 65.1115 False
1 9 25.0833 0.5831 -27.94 78.1067 False
3 7 -17.5889 0.6145 -56.3117 21.1339 False
3 9 -2.1389 0.9984 -37.2545 32.9767 False
7 9 15.45 0.6136 -18.5233 49.4233 False
-----------------------------------------------------
Corrected p-values: [0.92175 0.9984 0.92175 0.92175 0.9984 0.92175]
OLS Regression Results
===============================================================================
Dep. Variable: OP_relative_score_1 R-squared: 0.070
Model: OLS Adj. R-squared: 0.038
Method: Least Squares F-statistic: 2.162
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.0984
Time: 09:15:39 Log-Likelihood: -435.69
No. Observations: 90 AIC: 879.4
Df Residuals: 86 BIC: 889.4
Df Model: 3
Covariance Type: nonrobust
===============================================================================================
coef std err t P>|t| [0.025 0.975]
-----------------------------------------------------------------------------------------------
const -7.6060 3.383 -2.248 0.027 -14.332 -0.880
OP_distance_from_max_scaled -0.6529 4.214 -0.155 0.877 -9.030 7.724
average_distance_scaled 0.8907 3.412 0.261 0.795 -5.891 7.673
interaction 7.4655 3.522 2.119 0.037 0.463 14.468
==============================================================================
Omnibus: 42.283 Durbin-Watson: 1.871
Prob(Omnibus): 0.000 Jarque-Bera (JB): 6.957
Skew: 0.235 Prob(JB): 0.0308
Kurtosis: 1.722 Cond. No. 2.17
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
ANOVA results: F-statistic = 2.7626747055907366, p-value = 0.058031488320304726
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=======================================================
group1 group2 meandiff p-adj lower upper reject
-------------------------------------------------------
1 3 -41.3571 0.4103 -112.7952 30.0809 False
1 7 -23.0571 0.4949 -66.9655 20.8513 False
1 9 8.0252 0.9476 -31.9881 48.0385 False
3 7 18.3 0.889 -50.7157 87.3157 False
3 9 49.3824 0.206 -17.2231 115.9878 False
7 9 31.0824 0.1033 -4.4259 66.5906 False
-------------------------------------------------------
Corrected p-values: [0.74235 0.74235 0.9476 0.9476 0.618 0.618 ]
OLS Regression Results
===============================================================================
Dep. Variable: CO_relative_score_1 R-squared: 0.007
Model: OLS Adj. R-squared: -0.027
Method: Least Squares F-statistic: 0.2161
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.885
Time: 09:15:40 Log-Likelihood: -436.10
No. Observations: 90 AIC: 880.2
Df Residuals: 86 BIC: 890.2
Df Model: 3
Covariance Type: nonrobust
===============================================================================================
coef std err t P>|t| [0.025 0.975]
-----------------------------------------------------------------------------------------------
const -1.4752 3.368 -0.438 0.662 -8.170 5.220
CO_distance_from_max_scaled 3.0570 4.028 0.759 0.450 -4.949 11.064
average_distance_scaled 0.0336 3.404 0.010 0.992 -6.734 6.801
interaction -2.2010 3.432 -0.641 0.523 -9.024 4.622
==============================================================================
Omnibus: 32.707 Durbin-Watson: 2.139
Prob(Omnibus): 0.000 Jarque-Bera (JB): 5.705
Skew: 0.056 Prob(JB): 0.0577
Kurtosis: 1.772 Cond. No. 2.03
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
ANOVA results: F-statistic = 0.6398566094497207, p-value = 0.5946230850706252
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
1 3 25.125 0.6127 -30.0523 80.3023 False
1 7 23.9773 0.612 -28.6322 76.5867 False
1 9 24.3167 0.5722 -26.3878 75.0211 False
3 7 -1.1477 0.9999 -43.0155 40.7201 False
3 9 -0.8083 0.9999 -40.2557 38.639 False
7 9 0.3394 1.0 -35.4282 36.107 False
-----------------------------------------------------
Corrected p-values: [1. 1. 1. 1. 1. 1.]
OLS Regression Results
===============================================================================
Dep. Variable: AG_relative_score_1 R-squared: 0.002
Model: OLS Adj. R-squared: -0.033
Method: Least Squares F-statistic: 0.04428
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.988
Time: 09:15:40 Log-Likelihood: -421.59
No. Observations: 90 AIC: 851.2
Df Residuals: 86 BIC: 861.2
Df Model: 3
Covariance Type: nonrobust
===============================================================================================
coef std err t P>|t| [0.025 0.975]
-----------------------------------------------------------------------------------------------
const 9.2085 2.872 3.206 0.002 3.499 14.918
AG_distance_from_max_scaled -0.4963 3.192 -0.156 0.877 -6.841 5.848
average_distance_scaled 0.9301 2.932 0.317 0.752 -4.898 6.758
interaction 0.2900 2.602 0.111 0.912 -4.883 5.463
==============================================================================
Omnibus: 5.765 Durbin-Watson: 1.893
Prob(Omnibus): 0.056 Jarque-Bera (JB): 5.048
Skew: -0.495 Prob(JB): 0.0801
Kurtosis: 2.396 Cond. No. 1.83
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
ANOVA results: F-statistic = 0.35178865412898275, p-value = 0.7881234128801623
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
1 3 5.6 0.9918 -47.8957 59.0957 False
1 7 -2.4286 0.9992 -52.4124 47.5553 False
1 9 -8.4211 0.9534 -52.2912 35.4491 False
3 7 -8.0286 0.9658 -54.7234 38.6663 False
3 9 -14.0211 0.7786 -54.1037 26.0616 False
7 9 -5.9925 0.9669 -41.2517 29.2668 False
-----------------------------------------------------
Corrected p-values: [0.9992 0.9992 0.9992 0.9992 0.9992 0.9992]
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
1 3 5.6 0.9918 -47.8957 59.0957 False
1 7 -2.4286 0.9992 -52.4124 47.5553 False
1 9 -8.4211 0.9534 -52.2912 35.4491 False
3 7 -8.0286 0.9658 -54.7234 38.6663 False
3 9 -14.0211 0.7786 -54.1037 26.0616 False
7 9 -5.9925 0.9669 -41.2517 29.2668 False
-----------------------------------------------------
Corrected p-values: [0.9992 0.9992 0.9992 0.9992 0.9992 0.9992]
In [ ]:
# 総合的な効果の分析
data['overall_blended_preference'] = data[[f'{trait}_relative_score_1' for trait in ['EX', 'OP', 'CO', 'AG']]].mean(axis=1)
model = smf.ols('overall_blended_preference ~ average_distance_scaled', data=data)
results = model.fit()
print("\nOverall Blended Preference Analysis:")
print(results.summary())
Overall Blended Preference Analysis:
OLS Regression Results
======================================================================================
Dep. Variable: overall_blended_preference R-squared: 0.021
Model: OLS Adj. R-squared: 0.010
Method: Least Squares F-statistic: 1.871
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.175
Time: 07:59:52 Log-Likelihood: -377.19
No. Observations: 90 AIC: 758.4
Df Residuals: 88 BIC: 763.4
Df Model: 1
Covariance Type: nonrobust
===========================================================================================
coef std err t P>|t| [0.025 0.975]
-------------------------------------------------------------------------------------------
Intercept 1.1778 1.705 0.691 0.491 -2.210 4.566
average_distance_scaled 2.3316 1.705 1.368 0.175 -1.056 5.719
==============================================================================
Omnibus: 0.996 Durbin-Watson: 1.927
Prob(Omnibus): 0.608 Jarque-Bera (JB): 1.068
Skew: 0.235 Prob(JB): 0.586
Kurtosis: 2.747 Cond. No. 1.00
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
sandbox 3 hlm¶
In [ ]:
import pandas as pd
import numpy as np
import statsmodels.api as sm
import statsmodels.formula.api as smf
from scipy import stats
import matplotlib.pyplot as plt
import seaborn as sns
# データの読み込み(既存のデータフレームを 'data' とします)
data = merged_df
# 1. データの準備
# ロングフォーマットへの変換
traits = ['EX', 'OP', 'CO', 'AG']
questions = ['preference', 'believability', 'overall_liking', 'persuasiveness', 'interest', 'click_likelihood']
long_data = []
for trait in traits:
for q_num, question in enumerate(questions, 1):
temp_df = data[['ResponseId', f'{trait}_distance_from_max', 'average_distance'] +
[f'Ads_{trait}_{i}' for i in range(1, 7)]].copy()
temp_df['trait'] = trait
temp_df['question'] = question
temp_df['specialized_score'] = temp_df[f'Ads_{trait}_1']
temp_df['blended_score'] = temp_df[f'Ads_{trait}_{q_num}']
long_data.append(temp_df)
long_df = pd.concat(long_data, ignore_index=True)
# 相対的選好スコアの計算
long_df['relative_score'] = long_df['blended_score'] - long_df['specialized_score']
# 2. 階層線形モデルの構築
# ヌルモデル
null_model = smf.mixedlm("relative_score ~ 1", data=long_df, groups="ResponseId")
null_fit = null_model.fit()
print("Null Model Results:")
print(null_fit.summary())
# ランダム切片モデル
random_intercept_model = smf.mixedlm("relative_score ~ trait + question", data=long_df, groups="ResponseId")
random_intercept_fit = random_intercept_model.fit()
print("\nRandom Intercept Model Results:")
print(random_intercept_fit.summary())
# ランダム傾きモデル
random_slope_model = smf.mixedlm("relative_score ~ trait + question",
data=long_df,
groups="ResponseId",
re_formula="~trait")
random_slope_fit = random_slope_model.fit()
print("\nRandom Slope Model Results:")
print(random_slope_fit.summary())
# クロスレベル相互作用モデル
# エラーを回避するために、モデル式を修正
interaction_model = smf.mixedlm("relative_score ~ trait + question + trait:average_distance",
data=long_df,
groups="ResponseId",
re_formula="~trait")
interaction_fit = interaction_model.fit()
print("\nInteraction Model Results:")
print(interaction_fit.summary())
# 3. モデル比較
from statsmodels.tools.eval_measures import aic, bic
models = [null_fit, random_intercept_fit, random_slope_fit, interaction_fit]
model_names = ['Null', 'Random Intercept', 'Random Slope', 'Interaction']
comparison_df = pd.DataFrame({
'Model': model_names,
'AIC': [model.aic for model in models],
'BIC': [model.bic for model in models],
'Log-Likelihood': [model.llf for model in models]
})
print("\nModel Comparison:")
print(comparison_df)
# 4. 結果の可視化
# トレイトごとの相対的選好スコアの分布
plt.figure(figsize=(10, 6))
sns.boxplot(x='trait', y='relative_score', data=long_df)
plt.title('Distribution of Relative Preference Scores by Trait')
plt.show()
# average_distanceと相対的選好スコアの関係
plt.figure(figsize=(10, 6))
sns.scatterplot(x='average_distance', y='relative_score', hue='trait', data=long_df)
plt.title('Relative Preference Score vs Average Distance')
plt.show()
# 5. 予測プロット
# average_distanceの影響を予測
avg_distances = np.linspace(long_df['average_distance'].min(), long_df['average_distance'].max(), 100)
predictions = []
for trait in traits:
for distance in avg_distances:
pred_data = pd.DataFrame({
'trait': [trait],
'question': ['preference'],
'average_distance': [distance]
})
pred = interaction_fit.predict(pred_data)
predictions.append({'trait': trait, 'average_distance': distance, 'predicted_score': pred[0]})
pred_df = pd.DataFrame(predictions)
plt.figure(figsize=(10, 6))
for trait in traits:
trait_data = pred_df[pred_df['trait'] == trait]
plt.plot(trait_data['average_distance'], trait_data['predicted_score'], label=trait)
plt.xlabel('Average Distance')
plt.ylabel('Predicted Relative Preference Score')
plt.title('Predicted Relative Preference Score vs Average Distance by Trait')
plt.legend()
plt.show()
# 6. 仮説検証
# Blended広告が全体的に好まれているかのt検定
t_stat, p_value = stats.ttest_1samp(long_df['relative_score'], 0)
print("\nOne-sample t-test for overall preference of Blended ads:")
print(f"t-statistic: {t_stat}")
print(f"p-value: {p_value}")
# トレイトごとのBlended広告の選好
for trait in traits:
trait_scores = long_df[long_df['trait'] == trait]['relative_score']
t_stat, p_value = stats.ttest_1samp(trait_scores, 0)
print(f"\nOne-sample t-test for preference of Blended ads ({trait}):")
print(f"t-statistic: {t_stat}")
print(f"p-value: {p_value}")
Null Model Results:
Mixed Linear Model Regression Results
============================================================
Model: MixedLM Dependent Variable: relative_score
No. Observations: 2160 Method: REML
No. Groups: 90 Scale: 228.6478
Min. group size: 24 Log-Likelihood: -8994.8627
Max. group size: 24 Converged: Yes
Mean group size: 24.0
------------------------------------------------------------
Coef. Std.Err. z P>|z| [0.025 0.975]
------------------------------------------------------------
Intercept -0.635 0.664 -0.956 0.339 -1.936 0.667
ResponseId Var 30.158 0.402
============================================================
Random Intercept Model Results:
Mixed Linear Model Regression Results
=======================================================================
Model: MixedLM Dependent Variable: relative_score
No. Observations: 2160 Method: REML
No. Groups: 90 Scale: 228.6233
Min. group size: 24 Log-Likelihood: -8984.2356
Max. group size: 24 Converged: Yes
Mean group size: 24.0
-----------------------------------------------------------------------
Coef. Std.Err. z P>|z| [0.025 0.975]
-----------------------------------------------------------------------
Intercept 1.336 1.135 1.177 0.239 -0.888 3.560
trait[T.CO] -0.509 0.920 -0.553 0.580 -2.313 1.294
trait[T.EX] -0.919 0.920 -0.998 0.318 -2.722 0.885
trait[T.OP] -0.881 0.920 -0.958 0.338 -2.685 0.922
question[T.click_likelihood] -1.583 1.127 -1.405 0.160 -3.792 0.626
question[T.interest] -1.725 1.127 -1.531 0.126 -3.934 0.484
question[T.overall_liking] -1.522 1.127 -1.351 0.177 -3.731 0.687
question[T.persuasiveness] -2.769 1.127 -2.457 0.014 -4.978 -0.561
question[T.preference] -0.758 1.127 -0.673 0.501 -2.967 1.451
ResponseId Var 30.159 0.402
=======================================================================
Random Slope Model Results:
Mixed Linear Model Regression Results
=========================================================================
Model: MixedLM Dependent Variable: relative_score
No. Observations: 2160 Method: REML
No. Groups: 90 Scale: 142.3142
Min. group size: 24 Log-Likelihood: -8699.1813
Max. group size: 24 Converged: Yes
Mean group size: 24.0
-------------------------------------------------------------------------
Coef. Std.Err. z P>|z| [0.025 0.975]
-------------------------------------------------------------------------
Intercept 1.336 1.140 1.171 0.241 -0.899 3.571
trait[T.CO] -0.509 1.557 -0.327 0.744 -3.561 2.542
trait[T.EX] -0.919 1.150 -0.798 0.425 -3.173 1.336
trait[T.OP] -0.881 1.924 -0.458 0.647 -4.651 2.889
question[T.click_likelihood] -1.583 0.889 -1.781 0.075 -3.326 0.159
question[T.interest] -1.725 0.889 -1.940 0.052 -3.468 0.018
question[T.overall_liking] -1.522 0.889 -1.712 0.087 -3.265 0.221
question[T.persuasiveness] -2.769 0.889 -3.115 0.002 -4.512 -1.027
question[T.preference] -0.758 0.889 -0.853 0.394 -2.501 0.984
ResponseId Var 63.658 1.125
ResponseId x trait[T.CO] Cov -53.345 1.421
trait[T.CO] Var 170.741 2.808
ResponseId x trait[T.EX] Cov -46.281 1.116
trait[T.CO] x trait[T.EX] Cov 40.985 1.554
trait[T.EX] Var 71.678 1.533
ResponseId x trait[T.OP] Cov -57.587 1.694
trait[T.CO] x trait[T.OP] Cov 63.293 2.528
trait[T.EX] x trait[T.OP] Cov 21.314 1.818
trait[T.OP] Var 285.549 4.286
=========================================================================
Interaction Model Results:
Mixed Linear Model Regression Results
==========================================================================
Model: MixedLM Dependent Variable: relative_score
No. Observations: 2160 Method: REML
No. Groups: 90 Scale: 142.3136
Min. group size: 24 Log-Likelihood: -8688.0438
Max. group size: 24 Converged: Yes
Mean group size: 24.0
--------------------------------------------------------------------------
Coef. Std.Err. z P>|z| [0.025 0.975]
--------------------------------------------------------------------------
Intercept 4.947 2.715 1.822 0.068 -0.375 10.268
trait[T.CO] -5.344 4.208 -1.270 0.204 -13.591 2.903
trait[T.EX] -4.523 3.109 -1.455 0.146 -10.616 1.570
trait[T.OP] -5.056 5.222 -0.968 0.333 -15.291 5.178
question[T.click_likelihood] -1.583 0.889 -1.781 0.075 -3.326 0.159
question[T.interest] -1.725 0.889 -1.940 0.052 -3.468 0.018
question[T.overall_liking] -1.522 0.889 -1.712 0.087 -3.265 0.221
question[T.persuasiveness] -2.769 0.889 -3.115 0.002 -4.512 -1.027
question[T.preference] -0.758 0.889 -0.853 0.394 -2.501 0.984
trait[AG]:average_distance -5.834 3.985 -1.464 0.143 -13.644 1.977
trait[CO]:average_distance 1.977 5.305 0.373 0.709 -8.421 12.376
trait[EX]:average_distance -0.010 3.518 -0.003 0.998 -6.906 6.885
trait[OP]:average_distance 0.911 6.927 0.132 0.895 -12.665 14.487
ResponseId Var 62.552 1.116
ResponseId x trait[T.CO] Cov -51.408 1.410
trait[T.CO] Var 169.450 2.807
ResponseId x trait[T.EX] Cov -44.984 1.109
trait[T.CO] x trait[T.EX] Cov 38.918 1.547
trait[T.EX] Var 70.945 1.532
ResponseId x trait[T.OP] Cov -56.084 1.691
trait[T.CO] x trait[T.OP] Cov 61.035 2.532
trait[T.EX] x trait[T.OP] Cov 19.404 1.822
trait[T.OP] Var 286.544 4.322
==========================================================================
Model Comparison:
Model AIC BIC Log-Likelihood
0 Null NaN NaN -8994.862675
1 Random Intercept NaN NaN -8984.235623
2 Random Slope NaN NaN -8699.181282
3 Interaction NaN NaN -8688.043753
One-sample t-test for overall preference of Blended ads: t-statistic: -1.834808299174086 p-value: 0.06667161416861433 One-sample t-test for preference of Blended ads (EX): t-statistic: -1.7082776533603583 p-value: 0.08816058370201699 One-sample t-test for preference of Blended ads (OP): t-statistic: -1.0950299333662243 p-value: 0.2739925906530151 One-sample t-test for preference of Blended ads (CO): t-statistic: -0.7823966822943135 p-value: 0.43432506476910926 One-sample t-test for preference of Blended ads (AG): t-statistic: -0.0998911398122177 p-value: 0.920467892283989
sandbox 4¶
In [ ]:
import pandas as pd
import numpy as np
import matplotlib.pyplot as plt
import seaborn as sns
from scipy import stats
from sklearn.preprocessing import StandardScaler
from statsmodels.stats.anova import anova_lm
from statsmodels.formula.api import ols
# データの読み込み(既存のデータフレームを 'data' とします)
data = merged_df
# ステップ1: 相対的選好スコアの作成
traits = ['EX', 'OP', 'CO', 'AG']
questions = ['preference', 'believability', 'overall_liking', 'persuasiveness', 'interest', 'click_likelihood']
for trait in traits:
for i, question in enumerate(questions, 1):
data[f'{trait}_{question}_relative_score'] = data[f'Ads_{trait}_{i}'] - 50
In [ ]:
# ステップ2: 全体的な選好分析
"""
各特性(EX, OP, CO, AG)について、相対的選好スコアの平均値を計算する。
一標本のt検定を使用して、各特性の平均スコアが0と有意に異なるかを検証する。
コメント: この分析により、全体としてBlended広告が好まれているか、
あるいは特定の特性でBlended広告が特に効果的かを把握できます。
"""
def overall_preference_analysis(trait):
for question in questions:
score = data[f'{trait}_{question}_relative_score']
t_stat, p_value = stats.ttest_1samp(score, 0)
print(f"{trait} - {question}:")
print(f"Mean score: {score.mean():.2f}")
print(f"T-statistic: {t_stat:.2f}, p-value: {p_value:.4f}\n")
for trait in traits:
overall_preference_analysis(trait)
EX - preference: Mean score: 3.34 T-statistic: 0.95, p-value: 0.3447 EX - believability: Mean score: 1.11 T-statistic: 0.35, p-value: 0.7277 EX - overall_liking: Mean score: 2.78 T-statistic: 0.77, p-value: 0.4438 EX - persuasiveness: Mean score: 0.62 T-statistic: 0.18, p-value: 0.8550 EX - interest: Mean score: 3.32 T-statistic: 0.92, p-value: 0.3588 EX - click_likelihood: Mean score: 3.03 T-statistic: 0.82, p-value: 0.4156 OP - preference: Mean score: -6.06 T-statistic: -1.80, p-value: 0.0755 OP - believability: Mean score: -4.21 T-statistic: -1.51, p-value: 0.1351 OP - overall_liking: Mean score: -6.90 T-statistic: -2.01, p-value: 0.0474 OP - persuasiveness: Mean score: -8.52 T-statistic: -2.70, p-value: 0.0084 OP - interest: Mean score: -8.23 T-statistic: -2.53, p-value: 0.0131 OP - click_likelihood: Mean score: -8.04 T-statistic: -2.36, p-value: 0.0206 CO - preference: Mean score: -1.84 T-statistic: -0.56, p-value: 0.5746 CO - believability: Mean score: -0.87 T-statistic: -0.29, p-value: 0.7729 CO - overall_liking: Mean score: -3.64 T-statistic: -1.07, p-value: 0.2865 CO - persuasiveness: Mean score: -2.84 T-statistic: -0.89, p-value: 0.3756 CO - interest: Mean score: -2.16 T-statistic: -0.65, p-value: 0.5198 CO - click_likelihood: Mean score: -3.11 T-statistic: -0.86, p-value: 0.3921 AG - preference: Mean score: 9.27 T-statistic: 3.34, p-value: 0.0012 AG - believability: Mean score: 11.71 T-statistic: 4.62, p-value: 0.0000 AG - overall_liking: Mean score: 9.42 T-statistic: 3.20, p-value: 0.0019 AG - persuasiveness: Mean score: 7.41 T-statistic: 2.71, p-value: 0.0080 AG - interest: Mean score: 7.91 T-statistic: 2.79, p-value: 0.0064 AG - click_likelihood: Mean score: 9.53 T-statistic: 3.13, p-value: 0.0024
In [ ]:
# ステップ3: 距離の影響分析
"""
各参加者について、以下の2つの距離を計算する:
a) Blended personaからの距離(既に計算済みのaverage_distance)
b) Single Trait最大スコア(5)からの距離(既に計算済みの{trait}_distance_from_max)
これらの距離と相対的選好スコアの関係を散布図で可視化する。
距離と相対的選好スコアの相関分析を行う。
コメント: この分析により、参加者の特性プロファイルと広告の選好との関係を理解できます。
また、どちらの距離がより強く選好に影響しているかを把握できます。
"""
def distance_analysis(trait):
for question in questions:
# Blended personaからの距離との相関
corr_blended = stats.pearsonr(data['average_distance'], data[f'{trait}_{question}_relative_score'])
# Single Trait最大スコアからの距離との相関
corr_single = stats.pearsonr(data[f'{trait}_distance_from_max'], data[f'{trait}_{question}_relative_score'])
print(f"{trait} - {question}:")
print(f"Correlation with Blended distance: r={corr_blended[0]:.2f}, p={corr_blended[1]:.4f}")
print(f"Correlation with Single Trait distance: r={corr_single[0]:.2f}, p={corr_single[1]:.4f}\n")
# 散布図
plt.figure(figsize=(12, 5))
plt.subplot(1, 2, 1)
sns.scatterplot(x='average_distance', y=f'{trait}_{question}_relative_score', data=data)
plt.title(f"{trait} - {question} vs Blended Distance")
plt.subplot(1, 2, 2)
sns.scatterplot(x=f'{trait}_distance_from_max', y=f'{trait}_{question}_relative_score', data=data)
plt.title(f"{trait} - {question} vs Single Trait Distance")
plt.tight_layout()
plt.show()
for trait in traits:
distance_analysis(trait)
EX - preference: Correlation with Blended distance: r=0.23, p=0.0303 Correlation with Single Trait distance: r=0.26, p=0.0151
EX - believability: Correlation with Blended distance: r=0.21, p=0.0493 Correlation with Single Trait distance: r=0.29, p=0.0063
EX - overall_liking: Correlation with Blended distance: r=0.24, p=0.0249 Correlation with Single Trait distance: r=0.15, p=0.1455
EX - persuasiveness: Correlation with Blended distance: r=0.22, p=0.0355 Correlation with Single Trait distance: r=0.25, p=0.0193
EX - interest: Correlation with Blended distance: r=0.27, p=0.0100 Correlation with Single Trait distance: r=0.24, p=0.0233
EX - click_likelihood: Correlation with Blended distance: r=0.21, p=0.0466 Correlation with Single Trait distance: r=0.25, p=0.0153
OP - preference: Correlation with Blended distance: r=0.03, p=0.8057 Correlation with Single Trait distance: r=0.15, p=0.1675
OP - believability: Correlation with Blended distance: r=0.02, p=0.8770 Correlation with Single Trait distance: r=0.08, p=0.4466
OP - overall_liking: Correlation with Blended distance: r=-0.01, p=0.9476 Correlation with Single Trait distance: r=0.08, p=0.4338
OP - persuasiveness: Correlation with Blended distance: r=0.08, p=0.4485 Correlation with Single Trait distance: r=0.14, p=0.1893
OP - interest: Correlation with Blended distance: r=0.04, p=0.7074 Correlation with Single Trait distance: r=0.10, p=0.3571
OP - click_likelihood: Correlation with Blended distance: r=0.05, p=0.6276 Correlation with Single Trait distance: r=0.11, p=0.3235
CO - preference: Correlation with Blended distance: r=-0.00, p=0.9955 Correlation with Single Trait distance: r=0.05, p=0.6300
CO - believability: Correlation with Blended distance: r=-0.06, p=0.5701 Correlation with Single Trait distance: r=-0.04, p=0.7128
CO - overall_liking: Correlation with Blended distance: r=0.04, p=0.6959 Correlation with Single Trait distance: r=0.02, p=0.8766
CO - persuasiveness: Correlation with Blended distance: r=0.05, p=0.6333 Correlation with Single Trait distance: r=0.02, p=0.8212
CO - interest: Correlation with Blended distance: r=0.04, p=0.6887 Correlation with Single Trait distance: r=0.03, p=0.7436
CO - click_likelihood: Correlation with Blended distance: r=0.01, p=0.9319 Correlation with Single Trait distance: r=0.04, p=0.7276
AG - preference: Correlation with Blended distance: r=0.04, p=0.7425 Correlation with Single Trait distance: r=-0.01, p=0.9587
AG - believability: Correlation with Blended distance: r=-0.05, p=0.6537 Correlation with Single Trait distance: r=-0.10, p=0.3446
AG - overall_liking: Correlation with Blended distance: r=-0.06, p=0.6058 Correlation with Single Trait distance: r=-0.01, p=0.9320
AG - persuasiveness: Correlation with Blended distance: r=0.01, p=0.9442 Correlation with Single Trait distance: r=0.03, p=0.8143
AG - interest: Correlation with Blended distance: r=-0.03, p=0.7669 Correlation with Single Trait distance: r=0.03, p=0.7835
AG - click_likelihood: Correlation with Blended distance: r=-0.02, p=0.8280 Correlation with Single Trait distance: r=0.03, p=0.7614
In [ ]:
# ステップ4: 広告効果の多面的分析
# ステップ2と3の分析を各質問について繰り返す(上記のコードで既に実装済み)
"""
6つの質問(好ましさ、信頼性、全体的な好み、説得力、興味、クリック可能性)それぞれについて、
ステップ2と3の分析を繰り返す。
コメント: この分析により、Blended広告が特に効果的な側面
(例:信頼性は高いが、クリック可能性は低いなど)を特定できます。
"""
def multifaceted_ad_effect_analysis(trait):
for question in questions:
print(f"\n{trait} - {question} 分析結果:")
# 1. 全体的な選好分析(ステップ2の一部)
score = data[f'{trait}_{question}_relative_score']
t_stat, p_value = stats.ttest_1samp(score, 0)
print(f"全体的な選好:")
print(f"平均スコア: {score.mean():.2f}")
print(f"T統計量: {t_stat:.2f}, p値: {p_value:.4f}")
# 2. 距離の影響分析(ステップ3の一部)
corr_blended = stats.pearsonr(data['average_distance'], score)
corr_single = stats.pearsonr(data[f'{trait}_distance_from_max'], score)
print("\n距離との相関:")
print(f"Blended距離との相関: r={corr_blended[0]:.2f}, p={corr_blended[1]:.4f}")
print(f"Single Trait距離との相関: r={corr_single[0]:.2f}, p={corr_single[1]:.4f}")
# 3. 散布図の作成
plt.figure(figsize=(12, 5))
plt.subplot(1, 2, 1)
sns.scatterplot(x='average_distance', y=f'{trait}_{question}_relative_score', data=data)
plt.title(f"{trait} - {question} vs Blended Distance")
plt.subplot(1, 2, 2)
sns.scatterplot(x=f'{trait}_distance_from_max', y=f'{trait}_{question}_relative_score', data=data)
plt.title(f"{trait} - {question} vs Single Trait Distance")
plt.tight_layout()
plt.show()
# 4. 回帰分析
model = smf.ols(f'{trait}_{question}_relative_score ~ average_distance + {trait}_distance_from_max', data=data)
results = model.fit()
print("\n回帰分析結果:")
print(results.summary())
print("\n" + "="*50)
# 各特性について多面的分析を実行
for trait in traits:
multifaceted_ad_effect_analysis(trait)
# 質問間の相関分析
def question_correlation_analysis(trait):
correlation_matrix = data[[f'{trait}_{q}_relative_score' for q in questions]].corr()
plt.figure(figsize=(10, 8))
sns.heatmap(correlation_matrix, annot=True, cmap='coolwarm', vmin=-1, vmax=1)
plt.title(f'{trait} - 質問間の相関')
plt.tight_layout()
plt.show()
for trait in traits:
question_correlation_analysis(trait)
# 質問間の比較
def question_comparison(trait):
scores = [data[f'{trait}_{q}_relative_score'] for q in questions]
f_statistic, p_value = stats.f_oneway(*scores)
print(f"\n{trait} - 質問間の比較 (ANOVA):")
print(f"F統計量: {f_statistic:.2f}, p値: {p_value:.4f}")
plt.figure(figsize=(10, 6))
sns.boxplot(data=pd.melt(data[[f'{trait}_{q}_relative_score' for q in questions]],
var_name='Question', value_name='Score'))
plt.title(f'{trait} - 質問ごとの相対的選好スコア分布')
plt.xticks(rotation=45)
plt.tight_layout()
plt.show()
for trait in traits:
question_comparison(trait)
EX - preference 分析結果: 全体的な選好: 平均スコア: 3.34 T統計量: 0.95, p値: 0.3447 距離との相関: Blended距離との相関: r=0.23, p=0.0303 Single Trait距離との相関: r=0.26, p=0.0151
回帰分析結果:
OLS Regression Results
========================================================================================
Dep. Variable: EX_preference_relative_score R-squared: 0.103
Model: OLS Adj. R-squared: 0.082
Method: Least Squares F-statistic: 4.986
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.00891
Time: 08:00:17 Log-Likelihood: -438.09
No. Observations: 90 AIC: 882.2
Df Residuals: 87 BIC: 889.7
Df Model: 2
Covariance Type: nonrobust
========================================================================================
coef std err t P>|t| [0.025 0.975]
----------------------------------------------------------------------------------------
Intercept -30.0137 11.175 -2.686 0.009 -52.226 -7.802
average_distance 26.4893 13.872 1.910 0.059 -1.083 54.062
EX_distance_from_max 8.8326 3.986 2.216 0.029 0.909 16.756
==============================================================================
Omnibus: 21.498 Durbin-Watson: 1.739
Prob(Omnibus): 0.000 Jarque-Bera (JB): 4.968
Skew: -0.102 Prob(JB): 0.0834
Kurtosis: 1.867 Cond. No. 11.5
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
==================================================
EX - believability 分析結果:
全体的な選好:
平均スコア: 1.11
T統計量: 0.35, p値: 0.7277
距離との相関:
Blended距離との相関: r=0.21, p=0.0493
Single Trait距離との相関: r=0.29, p=0.0063
回帰分析結果:
OLS Regression Results
===========================================================================================
Dep. Variable: EX_believability_relative_score R-squared: 0.110
Model: OLS Adj. R-squared: 0.090
Method: Least Squares F-statistic: 5.384
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.00624
Time: 08:00:18 Log-Likelihood: -428.58
No. Observations: 90 AIC: 863.2
Df Residuals: 87 BIC: 870.7
Df Model: 2
Covariance Type: nonrobust
========================================================================================
coef std err t P>|t| [0.025 0.975]
----------------------------------------------------------------------------------------
Intercept -29.3902 10.054 -2.923 0.004 -49.374 -9.407
average_distance 20.8114 12.480 1.668 0.099 -3.995 45.618
EX_distance_from_max 9.1750 3.586 2.558 0.012 2.047 16.303
==============================================================================
Omnibus: 9.881 Durbin-Watson: 1.766
Prob(Omnibus): 0.007 Jarque-Bera (JB): 3.406
Skew: 0.022 Prob(JB): 0.182
Kurtosis: 2.048 Cond. No. 11.5
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
==================================================
EX - overall_liking 分析結果:
全体的な選好:
平均スコア: 2.78
T統計量: 0.77, p値: 0.4438
距離との相関:
Blended距離との相関: r=0.24, p=0.0249
Single Trait距離との相関: r=0.15, p=0.1455
回帰分析結果:
OLS Regression Results
============================================================================================
Dep. Variable: EX_overall_liking_relative_score R-squared: 0.071
Model: OLS Adj. R-squared: 0.049
Method: Least Squares F-statistic: 3.312
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.0411
Time: 08:00:18 Log-Likelihood: -441.95
No. Observations: 90 AIC: 889.9
Df Residuals: 87 BIC: 897.4
Df Model: 2
Covariance Type: nonrobust
========================================================================================
coef std err t P>|t| [0.025 0.975]
----------------------------------------------------------------------------------------
Intercept -25.4264 11.664 -2.180 0.032 -48.611 -2.242
average_distance 30.3177 14.480 2.094 0.039 1.538 59.097
EX_distance_from_max 4.9147 4.161 1.181 0.241 -3.355 13.185
==============================================================================
Omnibus: 66.369 Durbin-Watson: 1.782
Prob(Omnibus): 0.000 Jarque-Bera (JB): 7.181
Skew: -0.103 Prob(JB): 0.0276
Kurtosis: 1.632 Cond. No. 11.5
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
==================================================
EX - persuasiveness 分析結果:
全体的な選好:
平均スコア: 0.62
T統計量: 0.18, p値: 0.8550
距離との相関:
Blended距離との相関: r=0.22, p=0.0355
Single Trait距離との相関: r=0.25, p=0.0193
回帰分析結果:
OLS Regression Results
============================================================================================
Dep. Variable: EX_persuasiveness_relative_score R-squared: 0.096
Model: OLS Adj. R-squared: 0.075
Method: Least Squares F-statistic: 4.631
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.0123
Time: 08:00:19 Log-Likelihood: -435.15
No. Observations: 90 AIC: 876.3
Df Residuals: 87 BIC: 883.8
Df Model: 2
Covariance Type: nonrobust
========================================================================================
coef std err t P>|t| [0.025 0.975]
----------------------------------------------------------------------------------------
Intercept -30.5094 10.815 -2.821 0.006 -52.006 -9.013
average_distance 24.8439 13.426 1.850 0.068 -1.841 51.529
EX_distance_from_max 8.2035 3.858 2.126 0.036 0.535 15.871
==============================================================================
Omnibus: 25.099 Durbin-Watson: 1.671
Prob(Omnibus): 0.000 Jarque-Bera (JB): 5.164
Skew: 0.047 Prob(JB): 0.0756
Kurtosis: 1.830 Cond. No. 11.5
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
==================================================
EX - interest 分析結果:
全体的な選好:
平均スコア: 3.32
T統計量: 0.92, p値: 0.3588
距離との相関:
Blended距離との相関: r=0.27, p=0.0100
Single Trait距離との相関: r=0.24, p=0.0233
回帰分析結果:
OLS Regression Results
======================================================================================
Dep. Variable: EX_interest_relative_score R-squared: 0.114
Model: OLS Adj. R-squared: 0.094
Method: Least Squares F-statistic: 5.592
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.00519
Time: 08:00:19 Log-Likelihood: -439.57
No. Observations: 90 AIC: 885.1
Df Residuals: 87 BIC: 892.6
Df Model: 2
Covariance Type: nonrobust
========================================================================================
coef std err t P>|t| [0.025 0.975]
----------------------------------------------------------------------------------------
Intercept -32.8947 11.360 -2.896 0.005 -55.473 -10.316
average_distance 33.3058 14.101 2.362 0.020 5.278 61.333
EX_distance_from_max 8.1241 4.052 2.005 0.048 0.070 16.178
==============================================================================
Omnibus: 24.032 Durbin-Watson: 1.687
Prob(Omnibus): 0.000 Jarque-Bera (JB): 5.290
Skew: -0.133 Prob(JB): 0.0710
Kurtosis: 1.843 Cond. No. 11.5
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
==================================================
EX - click_likelihood 分析結果:
全体的な選好:
平均スコア: 3.03
T統計量: 0.82, p値: 0.4156
距離との相関:
Blended距離との相関: r=0.21, p=0.0466
Single Trait距離との相関: r=0.25, p=0.0153
回帰分析結果:
OLS Regression Results
==============================================================================================
Dep. Variable: EX_click_likelihood_relative_score R-squared: 0.096
Model: OLS Adj. R-squared: 0.075
Method: Least Squares F-statistic: 4.612
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.0125
Time: 08:00:20 Log-Likelihood: -443.11
No. Observations: 90 AIC: 892.2
Df Residuals: 87 BIC: 899.7
Df Model: 2
Covariance Type: nonrobust
========================================================================================
coef std err t P>|t| [0.025 0.975]
----------------------------------------------------------------------------------------
Intercept -30.6494 11.816 -2.594 0.011 -54.135 -7.163
average_distance 25.2738 14.668 1.723 0.088 -3.880 54.428
EX_distance_from_max 9.3934 4.215 2.229 0.028 1.016 17.771
==============================================================================
Omnibus: 27.502 Durbin-Watson: 1.736
Prob(Omnibus): 0.000 Jarque-Bera (JB): 5.457
Skew: -0.101 Prob(JB): 0.0653
Kurtosis: 1.811 Cond. No. 11.5
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
==================================================
OP - preference 分析結果:
全体的な選好:
平均スコア: -6.06
T統計量: -1.80, p値: 0.0755
距離との相関:
Blended距離との相関: r=0.03, p=0.8057
Single Trait距離との相関: r=0.15, p=0.1675
回帰分析結果:
OLS Regression Results
========================================================================================
Dep. Variable: OP_preference_relative_score R-squared: 0.022
Model: OLS Adj. R-squared: -0.001
Method: Least Squares F-statistic: 0.9581
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.388
Time: 08:00:20 Log-Likelihood: -437.98
No. Observations: 90 AIC: 882.0
Df Residuals: 87 BIC: 889.5
Df Model: 2
Covariance Type: nonrobust
========================================================================================
coef std err t P>|t| [0.025 0.975]
----------------------------------------------------------------------------------------
Intercept -13.6485 9.981 -1.367 0.175 -33.487 6.191
average_distance -0.5649 14.018 -0.040 0.968 -28.427 27.297
OP_distance_from_max 6.4303 4.722 1.362 0.177 -2.954 15.815
==============================================================================
Omnibus: 38.063 Durbin-Watson: 1.888
Prob(Omnibus): 0.000 Jarque-Bera (JB): 6.967
Skew: 0.267 Prob(JB): 0.0307
Kurtosis: 1.746 Cond. No. 8.67
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
==================================================
OP - believability 分析結果:
全体的な選好:
平均スコア: -4.21
T統計量: -1.51, p値: 0.1351
距離との相関:
Blended距離との相関: r=0.02, p=0.8770
Single Trait距離との相関: r=0.08, p=0.4466
回帰分析結果:
OLS Regression Results
===========================================================================================
Dep. Variable: OP_believability_relative_score R-squared: 0.007
Model: OLS Adj. R-squared: -0.016
Method: Least Squares F-statistic: 0.2889
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.750
Time: 08:00:21 Log-Likelihood: -421.82
No. Observations: 90 AIC: 849.6
Df Residuals: 87 BIC: 857.1
Df Model: 2
Covariance Type: nonrobust
========================================================================================
coef std err t P>|t| [0.025 0.975]
----------------------------------------------------------------------------------------
Intercept -7.8151 8.341 -0.937 0.351 -24.393 8.763
average_distance -0.0367 11.713 -0.003 0.998 -23.318 23.245
OP_distance_from_max 2.9361 3.945 0.744 0.459 -4.906 10.778
==============================================================================
Omnibus: 3.824 Durbin-Watson: 2.223
Prob(Omnibus): 0.148 Jarque-Bera (JB): 2.089
Skew: 0.064 Prob(JB): 0.352
Kurtosis: 2.265 Cond. No. 8.67
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
==================================================
OP - overall_liking 分析結果:
全体的な選好:
平均スコア: -6.90
T統計量: -2.01, p値: 0.0474
距離との相関:
Blended距離との相関: r=-0.01, p=0.9476
Single Trait距離との相関: r=0.08, p=0.4338
回帰分析結果:
OLS Regression Results
============================================================================================
Dep. Variable: OP_overall_liking_relative_score R-squared: 0.008
Model: OLS Adj. R-squared: -0.015
Method: Least Squares F-statistic: 0.3331
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.718
Time: 08:00:21 Log-Likelihood: -440.33
No. Observations: 90 AIC: 886.7
Df Residuals: 87 BIC: 894.2
Df Model: 2
Covariance Type: nonrobust
========================================================================================
coef std err t P>|t| [0.025 0.975]
----------------------------------------------------------------------------------------
Intercept -9.6923 10.246 -0.946 0.347 -30.057 10.672
average_distance -3.3568 14.389 -0.233 0.816 -31.956 25.243
OP_distance_from_max 3.9428 4.847 0.814 0.418 -5.690 13.576
==============================================================================
Omnibus: 46.816 Durbin-Watson: 1.936
Prob(Omnibus): 0.000 Jarque-Bera (JB): 7.457
Skew: 0.276 Prob(JB): 0.0240
Kurtosis: 1.702 Cond. No. 8.67
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
==================================================
OP - persuasiveness 分析結果:
全体的な選好:
平均スコア: -8.52
T統計量: -2.70, p値: 0.0084
距離との相関:
Blended距離との相関: r=0.08, p=0.4485
Single Trait距離との相関: r=0.14, p=0.1893
回帰分析結果:
OLS Regression Results
============================================================================================
Dep. Variable: OP_persuasiveness_relative_score R-squared: 0.022
Model: OLS Adj. R-squared: -0.000
Method: Least Squares F-statistic: 0.9930
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.375
Time: 08:00:22 Log-Likelihood: -432.26
No. Observations: 90 AIC: 870.5
Df Residuals: 87 BIC: 878.0
Df Model: 2
Covariance Type: nonrobust
========================================================================================
coef std err t P>|t| [0.025 0.975]
----------------------------------------------------------------------------------------
Intercept -19.0802 9.366 -2.037 0.045 -37.697 -0.464
average_distance 6.5826 13.154 0.500 0.618 -19.562 32.727
OP_distance_from_max 5.2490 4.431 1.185 0.239 -3.557 14.055
==============================================================================
Omnibus: 13.810 Durbin-Watson: 1.966
Prob(Omnibus): 0.001 Jarque-Bera (JB): 5.697
Skew: 0.367 Prob(JB): 0.0579
Kurtosis: 2.010 Cond. No. 8.67
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
==================================================
OP - interest 分析結果:
全体的な選好:
平均スコア: -8.23
T統計量: -2.53, p値: 0.0131
距離との相関:
Blended距離との相関: r=0.04, p=0.7074
Single Trait距離との相関: r=0.10, p=0.3571
回帰分析結果:
OLS Regression Results
======================================================================================
Dep. Variable: OP_interest_relative_score R-squared: 0.010
Model: OLS Adj. R-squared: -0.013
Method: Least Squares F-statistic: 0.4416
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.644
Time: 08:00:22 Log-Likelihood: -435.37
No. Observations: 90 AIC: 876.7
Df Residuals: 87 BIC: 884.2
Df Model: 2
Covariance Type: nonrobust
========================================================================================
coef std err t P>|t| [0.025 0.975]
----------------------------------------------------------------------------------------
Intercept -14.7051 9.696 -1.517 0.133 -33.977 4.567
average_distance 2.5724 13.617 0.189 0.851 -24.493 29.638
OP_distance_from_max 3.9504 4.587 0.861 0.391 -5.166 13.067
==============================================================================
Omnibus: 17.137 Durbin-Watson: 2.016
Prob(Omnibus): 0.000 Jarque-Bera (JB): 6.616
Skew: 0.413 Prob(JB): 0.0366
Kurtosis: 1.959 Cond. No. 8.67
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
==================================================
OP - click_likelihood 分析結果:
全体的な選好:
平均スコア: -8.04
T統計量: -2.36, p値: 0.0206
距離との相関:
Blended距離との相関: r=0.05, p=0.6276
Single Trait距離との相関: r=0.11, p=0.3235
回帰分析結果:
OLS Regression Results
==============================================================================================
Dep. Variable: OP_click_likelihood_relative_score R-squared: 0.012
Model: OLS Adj. R-squared: -0.011
Method: Least Squares F-statistic: 0.5291
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.591
Time: 08:00:23 Log-Likelihood: -439.62
No. Observations: 90 AIC: 885.2
Df Residuals: 87 BIC: 892.7
Df Model: 2
Covariance Type: nonrobust
========================================================================================
coef std err t P>|t| [0.025 0.975]
----------------------------------------------------------------------------------------
Intercept -15.9680 10.164 -1.571 0.120 -36.171 4.235
average_distance 4.1037 14.275 0.287 0.774 -24.269 32.476
OP_distance_from_max 4.3584 4.808 0.906 0.367 -5.198 13.915
==============================================================================
Omnibus: 38.012 Durbin-Watson: 1.871
Prob(Omnibus): 0.000 Jarque-Bera (JB): 7.430
Skew: 0.323 Prob(JB): 0.0244
Kurtosis: 1.749 Cond. No. 8.67
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
==================================================
CO - preference 分析結果:
全体的な選好:
平均スコア: -1.84
T統計量: -0.56, p値: 0.5746
距離との相関:
Blended距離との相関: r=-0.00, p=0.9955
Single Trait距離との相関: r=0.05, p=0.6300
回帰分析結果:
OLS Regression Results
========================================================================================
Dep. Variable: CO_preference_relative_score R-squared: 0.003
Model: OLS Adj. R-squared: -0.020
Method: Least Squares F-statistic: 0.1193
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.888
Time: 08:00:23 Log-Likelihood: -436.31
No. Observations: 90 AIC: 878.6
Df Residuals: 87 BIC: 886.1
Df Model: 2
Covariance Type: nonrobust
========================================================================================
coef std err t P>|t| [0.025 0.975]
----------------------------------------------------------------------------------------
Intercept -3.4064 9.550 -0.357 0.722 -22.388 15.575
average_distance -1.1954 13.654 -0.088 0.930 -28.333 25.942
CO_distance_from_max 2.2157 4.536 0.488 0.626 -6.800 11.231
==============================================================================
Omnibus: 40.136 Durbin-Watson: 2.122
Prob(Omnibus): 0.000 Jarque-Bera (JB): 6.125
Skew: 0.064 Prob(JB): 0.0468
Kurtosis: 1.728 Cond. No. 8.00
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
==================================================
CO - believability 分析結果:
全体的な選好:
平均スコア: -0.87
T統計量: -0.29, p値: 0.7729
距離との相関:
Blended距離との相関: r=-0.06, p=0.5701
Single Trait距離との相関: r=-0.04, p=0.7128
回帰分析結果:
OLS Regression Results
===========================================================================================
Dep. Variable: CO_believability_relative_score R-squared: 0.005
Model: OLS Adj. R-squared: -0.018
Method: Least Squares F-statistic: 0.1990
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.820
Time: 08:00:24 Log-Likelihood: -428.20
No. Observations: 90 AIC: 862.4
Df Residuals: 87 BIC: 869.9
Df Model: 2
Covariance Type: nonrobust
========================================================================================
coef std err t P>|t| [0.025 0.975]
----------------------------------------------------------------------------------------
Intercept 4.2826 8.727 0.491 0.625 -13.063 21.628
average_distance -6.3952 12.476 -0.513 0.610 -31.193 18.403
CO_distance_from_max -1.1462 4.145 -0.277 0.783 -9.384 7.092
==============================================================================
Omnibus: 6.127 Durbin-Watson: 2.068
Prob(Omnibus): 0.047 Jarque-Bera (JB): 2.687
Skew: 0.052 Prob(JB): 0.261
Kurtosis: 2.160 Cond. No. 8.00
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
==================================================
CO - overall_liking 分析結果:
全体的な選好:
平均スコア: -3.64
T統計量: -1.07, p値: 0.2865
距離との相関:
Blended距離との相関: r=0.04, p=0.6959
Single Trait距離との相関: r=0.02, p=0.8766
回帰分析結果:
OLS Regression Results
============================================================================================
Dep. Variable: CO_overall_liking_relative_score R-squared: 0.002
Model: OLS Adj. R-squared: -0.021
Method: Least Squares F-statistic: 0.08013
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.923
Time: 08:00:24 Log-Likelihood: -439.72
No. Observations: 90 AIC: 885.4
Df Residuals: 87 BIC: 892.9
Df Model: 2
Covariance Type: nonrobust
========================================================================================
coef std err t P>|t| [0.025 0.975]
----------------------------------------------------------------------------------------
Intercept -7.3289 9.919 -0.739 0.462 -27.044 12.386
average_distance 5.2343 14.181 0.369 0.713 -22.952 33.420
CO_distance_from_max 0.4279 4.711 0.091 0.928 -8.936 9.791
==============================================================================
Omnibus: 73.154 Durbin-Watson: 1.993
Prob(Omnibus): 0.000 Jarque-Bera (JB): 7.397
Skew: 0.115 Prob(JB): 0.0248
Kurtosis: 1.615 Cond. No. 8.00
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
==================================================
CO - persuasiveness 分析結果:
全体的な選好:
平均スコア: -2.84
T統計量: -0.89, p値: 0.3756
距離との相関:
Blended距離との相関: r=0.05, p=0.6333
Single Trait距離との相関: r=0.02, p=0.8212
回帰分析結果:
OLS Regression Results
============================================================================================
Dep. Variable: CO_persuasiveness_relative_score R-squared: 0.003
Model: OLS Adj. R-squared: -0.020
Method: Least Squares F-statistic: 0.1242
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.883
Time: 08:00:25 Log-Likelihood: -434.09
No. Observations: 90 AIC: 874.2
Df Residuals: 87 BIC: 881.7
Df Model: 2
Covariance Type: nonrobust
========================================================================================
coef std err t P>|t| [0.025 0.975]
----------------------------------------------------------------------------------------
Intercept -7.1891 9.317 -0.772 0.442 -25.707 11.329
average_distance 5.9207 13.320 0.444 0.658 -20.555 32.396
CO_distance_from_max 0.6544 4.425 0.148 0.883 -8.141 9.450
==============================================================================
Omnibus: 25.081 Durbin-Watson: 2.014
Prob(Omnibus): 0.000 Jarque-Bera (JB): 5.246
Skew: 0.091 Prob(JB): 0.0726
Kurtosis: 1.831 Cond. No. 8.00
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
==================================================
CO - interest 分析結果:
全体的な選好:
平均スコア: -2.16
T統計量: -0.65, p値: 0.5198
距離との相関:
Blended距離との相関: r=0.04, p=0.6887
Single Trait距離との相関: r=0.03, p=0.7436
回帰分析結果:
OLS Regression Results
======================================================================================
Dep. Variable: CO_interest_relative_score R-squared: 0.003
Model: OLS Adj. R-squared: -0.020
Method: Least Squares F-statistic: 0.1145
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.892
Time: 08:00:26 Log-Likelihood: -438.00
No. Observations: 90 AIC: 882.0
Df Residuals: 87 BIC: 889.5
Df Model: 2
Covariance Type: nonrobust
========================================================================================
coef std err t P>|t| [0.025 0.975]
----------------------------------------------------------------------------------------
Intercept -6.4330 9.731 -0.661 0.510 -25.775 12.908
average_distance 4.8698 13.912 0.350 0.727 -22.782 32.522
CO_distance_from_max 1.2159 4.622 0.263 0.793 -7.970 10.402
==============================================================================
Omnibus: 32.478 Durbin-Watson: 2.024
Prob(Omnibus): 0.000 Jarque-Bera (JB): 5.788
Skew: 0.100 Prob(JB): 0.0554
Kurtosis: 1.774 Cond. No. 8.00
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
==================================================
CO - click_likelihood 分析結果:
全体的な選好:
平均スコア: -3.11
T統計量: -0.86, p値: 0.3921
距離との相関:
Blended距離との相関: r=0.01, p=0.9319
Single Trait距離との相関: r=0.04, p=0.7276
回帰分析結果:
OLS Regression Results
==============================================================================================
Dep. Variable: CO_click_likelihood_relative_score R-squared: 0.001
Model: OLS Adj. R-squared: -0.022
Method: Least Squares F-statistic: 0.06073
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.941
Time: 08:00:27 Log-Likelihood: -445.36
No. Observations: 90 AIC: 896.7
Df Residuals: 87 BIC: 904.2
Df Model: 2
Covariance Type: nonrobust
========================================================================================
coef std err t P>|t| [0.025 0.975]
----------------------------------------------------------------------------------------
Intercept -5.1280 10.560 -0.486 0.628 -26.117 15.861
average_distance 0.4140 15.097 0.027 0.978 -29.593 30.421
CO_distance_from_max 1.6947 5.015 0.338 0.736 -8.274 11.663
==============================================================================
Omnibus: 140.150 Durbin-Watson: 2.006
Prob(Omnibus): 0.000 Jarque-Bera (JB): 8.361
Skew: 0.089 Prob(JB): 0.0153
Kurtosis: 1.517 Cond. No. 8.00
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
==================================================
AG - preference 分析結果:
全体的な選好:
平均スコア: 9.27
T統計量: 3.34, p値: 0.0012
距離との相関:
Blended距離との相関: r=0.04, p=0.7425
Single Trait距離との相関: r=-0.01, p=0.9587
回帰分析結果:
OLS Regression Results
========================================================================================
Dep. Variable: AG_preference_relative_score R-squared: 0.001
Model: OLS Adj. R-squared: -0.022
Method: Least Squares F-statistic: 0.06090
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.941
Time: 08:00:27 Log-Likelihood: -421.60
No. Observations: 90 AIC: 849.2
Df Residuals: 87 BIC: 856.7
Df Model: 2
Covariance Type: nonrobust
========================================================================================
coef std err t P>|t| [0.025 0.975]
----------------------------------------------------------------------------------------
Intercept 7.3061 8.178 0.893 0.374 -8.948 23.561
average_distance 4.0273 11.668 0.345 0.731 -19.164 27.218
AG_distance_from_max -0.4921 4.104 -0.120 0.905 -8.650 7.666
==============================================================================
Omnibus: 5.821 Durbin-Watson: 1.892
Prob(Omnibus): 0.054 Jarque-Bera (JB): 5.091
Skew: -0.497 Prob(JB): 0.0784
Kurtosis: 2.394 Cond. No. 8.10
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
==================================================
AG - believability 分析結果:
全体的な選好:
平均スコア: 11.71
T統計量: 4.62, p値: 0.0000
距離との相関:
Blended距離との相関: r=-0.05, p=0.6537
Single Trait距離との相関: r=-0.10, p=0.3446
回帰分析結果:
OLS Regression Results
===========================================================================================
Dep. Variable: AG_believability_relative_score R-squared: 0.011
Model: OLS Adj. R-squared: -0.012
Method: Least Squares F-statistic: 0.4819
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.619
Time: 08:00:27 Log-Likelihood: -412.84
No. Observations: 90 AIC: 831.7
Df Residuals: 87 BIC: 839.2
Df Model: 2
Covariance Type: nonrobust
========================================================================================
coef std err t P>|t| [0.025 0.975]
----------------------------------------------------------------------------------------
Intercept 16.9634 7.419 2.286 0.025 2.217 31.710
average_distance -2.8071 10.585 -0.265 0.791 -23.846 18.232
AG_distance_from_max -3.2499 3.724 -0.873 0.385 -10.651 4.151
==============================================================================
Omnibus: 3.126 Durbin-Watson: 1.855
Prob(Omnibus): 0.209 Jarque-Bera (JB): 3.118
Skew: -0.426 Prob(JB): 0.210
Kurtosis: 2.675 Cond. No. 8.10
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
==================================================
AG - overall_liking 分析結果:
全体的な選好:
平均スコア: 9.42
T統計量: 3.20, p値: 0.0019
距離との相関:
Blended距離との相関: r=-0.06, p=0.6058
Single Trait距離との相関: r=-0.01, p=0.9320
回帰分析結果:
OLS Regression Results
============================================================================================
Dep. Variable: AG_overall_liking_relative_score R-squared: 0.003
Model: OLS Adj. R-squared: -0.020
Method: Least Squares F-statistic: 0.1328
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.876
Time: 08:00:28 Log-Likelihood: -426.72
No. Observations: 90 AIC: 859.4
Df Residuals: 87 BIC: 866.9
Df Model: 2
Covariance Type: nonrobust
========================================================================================
coef std err t P>|t| [0.025 0.975]
----------------------------------------------------------------------------------------
Intercept 13.2211 8.657 1.527 0.130 -3.986 30.428
average_distance -6.2777 12.351 -0.508 0.613 -30.827 18.272
AG_distance_from_max 0.0804 4.345 0.019 0.985 -8.555 8.716
==============================================================================
Omnibus: 6.489 Durbin-Watson: 1.944
Prob(Omnibus): 0.039 Jarque-Bera (JB): 4.136
Skew: -0.358 Prob(JB): 0.126
Kurtosis: 2.231 Cond. No. 8.10
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
==================================================
AG - persuasiveness 分析結果:
全体的な選好:
平均スコア: 7.41
T統計量: 2.71, p値: 0.0080
距離との相関:
Blended距離との相関: r=0.01, p=0.9442
Single Trait距離との相関: r=0.03, p=0.8143
回帰分析結果:
OLS Regression Results
============================================================================================
Dep. Variable: AG_persuasiveness_relative_score R-squared: 0.001
Model: OLS Adj. R-squared: -0.022
Method: Least Squares F-statistic: 0.02770
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.973
Time: 08:00:29 Log-Likelihood: -420.08
No. Observations: 90 AIC: 846.2
Df Residuals: 87 BIC: 853.7
Df Model: 2
Covariance Type: nonrobust
========================================================================================
coef std err t P>|t| [0.025 0.975]
----------------------------------------------------------------------------------------
Intercept 6.2646 8.041 0.779 0.438 -9.718 22.247
average_distance 0.2674 11.472 0.023 0.981 -22.535 23.070
AG_distance_from_max 0.9071 4.036 0.225 0.823 -7.114 8.928
==============================================================================
Omnibus: 3.105 Durbin-Watson: 1.897
Prob(Omnibus): 0.212 Jarque-Bera (JB): 2.529
Skew: -0.287 Prob(JB): 0.282
Kurtosis: 2.412 Cond. No. 8.10
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
==================================================
AG - interest 分析結果:
全体的な選好:
平均スコア: 7.91
T統計量: 2.79, p値: 0.0064
距離との相関:
Blended距離との相関: r=-0.03, p=0.7669
Single Trait距離との相関: r=0.03, p=0.7835
回帰分析結果:
OLS Regression Results
======================================================================================
Dep. Variable: AG_interest_relative_score R-squared: 0.002
Model: OLS Adj. R-squared: -0.021
Method: Least Squares F-statistic: 0.1017
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.903
Time: 08:00:29 Log-Likelihood: -423.28
No. Observations: 90 AIC: 852.6
Df Residuals: 87 BIC: 860.1
Df Model: 2
Covariance Type: nonrobust
========================================================================================
coef std err t P>|t| [0.025 0.975]
----------------------------------------------------------------------------------------
Intercept 9.0064 8.332 1.081 0.283 -7.554 25.566
average_distance -4.2575 11.887 -0.358 0.721 -27.884 19.369
AG_distance_from_max 1.4240 4.181 0.341 0.734 -6.887 9.735
==============================================================================
Omnibus: 7.231 Durbin-Watson: 1.966
Prob(Omnibus): 0.027 Jarque-Bera (JB): 3.538
Skew: -0.237 Prob(JB): 0.171
Kurtosis: 2.152 Cond. No. 8.10
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
==================================================
AG - click_likelihood 分析結果:
全体的な選好:
平均スコア: 9.53
T統計量: 3.13, p値: 0.0024
距離との相関:
Blended距離との相関: r=-0.02, p=0.8280
Single Trait距離との相関: r=0.03, p=0.7614
回帰分析結果:
OLS Regression Results
==============================================================================================
Dep. Variable: AG_click_likelihood_relative_score R-squared: 0.002
Model: OLS Adj. R-squared: -0.021
Method: Least Squares F-statistic: 0.08606
Date: Thu, 25 Jul 2024 Prob (F-statistic): 0.918
Time: 08:00:30 Log-Likelihood: -429.82
No. Observations: 90 AIC: 865.6
Df Residuals: 87 BIC: 873.1
Df Model: 2
Covariance Type: nonrobust
========================================================================================
coef std err t P>|t| [0.025 0.975]
----------------------------------------------------------------------------------------
Intercept 10.0560 8.959 1.122 0.265 -7.752 27.864
average_distance -3.6231 12.783 -0.283 0.778 -29.030 21.784
AG_distance_from_max 1.5903 4.497 0.354 0.724 -7.347 10.528
==============================================================================
Omnibus: 9.406 Durbin-Watson: 1.786
Prob(Omnibus): 0.009 Jarque-Bera (JB): 4.671
Skew: -0.337 Prob(JB): 0.0968
Kurtosis: 2.111 Cond. No. 8.10
==============================================================================
Notes:
[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.
==================================================
EX - 質問間の比較 (ANOVA): F統計量: 0.12, p値: 0.9890
OP - 質問間の比較 (ANOVA): F統計量: 0.26, p値: 0.9354
CO - 質問間の比較 (ANOVA): F統計量: 0.09, p値: 0.9937
AG - 質問間の比較 (ANOVA): F統計量: 0.29, p値: 0.9208
In [ ]:
# ステップ5: セグメント分析
"""
参加者を以下の2つの距離に基づいて分類する:
a) Blended personaからの距離(average_distance)
b) Single Trait最大スコア(5)からの距離
各距離について、参加者を3つのグループ(近い、中間、遠い)に分類する。
各グループ内で、相対的選好スコアの平均を計算し、グループ間で比較する。
Tukey's Honest Significant Difference (HSD) テストを使用することができます。
これは、多重比較の問題を考慮しつつ、すべてのグループペア間の差の有意性を検定する方法です。
二元配置分散分析(Two-way ANOVA)を使用して、Blended距離とSingle Trait距離の両方が
相対的選好スコアに与える影響を分析する。
コメント: この修正により、Blended personaからの距離とSingle Trait最大スコアからの
距離の両方を考慮したセグメント分析が可能になります。
これにより、どのような特性プロファイルを持つ人々にBlended広告が特に効果的か、
あるいはSingleが効果的かをより詳細に理解できます。
"""
from statsmodels.stats.multicomp import pairwise_tukeyhsd
from statsmodels.formula.api import ols
from statsmodels.stats.anova import anova_lm
def segment_analysis(trait):
# 距離のセグメント化
data['blended_segment'] = pd.qcut(data['average_distance'], q=3, labels=['近い', '中間', '遠い'])
data[f'{trait}_single_segment'] = pd.qcut(data[f'{trait}_distance_from_max'], q=3, labels=['近い', '中間', '遠い'])
for question in questions:
# グループごとの平均スコア計算
grouped_means = data.groupby(['blended_segment', f'{trait}_single_segment'])[f'{trait}_{question}_relative_score'].mean().unstack()
print(f"{trait} - {question} グループ平均:")
print(grouped_means)
print()
# 二元配置分散分析
model = ols(f'{trait}_{question}_relative_score ~ C(blended_segment) + C({trait}_single_segment) + C(blended_segment):C({trait}_single_segment)', data=data).fit()
anova_table = anova_lm(model, typ=2)
print(f"{trait} - {question} 二元配置分散分析結果:")
print(anova_table)
print()
# Tukey's HSDテスト
# blended_segmentに基づくグループ比較
tukey_blended = pairwise_tukeyhsd(data[f'{trait}_{question}_relative_score'], data['blended_segment'])
print("Tukey's HSD test for blended_segment:")
print(tukey_blended)
print()
# single_segmentに基づくグループ比較
tukey_single = pairwise_tukeyhsd(data[f'{trait}_{question}_relative_score'], data[f'{trait}_single_segment'])
print(f"Tukey's HSD test for {trait}_single_segment:")
print(tukey_single)
print()
# 交互作用のグループ比較
data['interaction_group'] = data['blended_segment'].astype(str) + '_' + data[f'{trait}_single_segment'].astype(str)
tukey_interaction = pairwise_tukeyhsd(data[f'{trait}_{question}_relative_score'], data['interaction_group'])
print("Tukey's HSD test for interaction groups:")
print(tukey_interaction)
print("\n" + "="*50 + "\n")
for trait in traits:
segment_analysis(trait)
EX - preference グループ平均:
EX_single_segment 近い 中間 遠い
blended_segment
近い -7.125000 -6.842105 25.400000
中間 0.133333 11.875000 -4.800000
遠い 3.300000 -4.000000 21.769231
EX - preference 二元配置分散分析結果:
sum_sq df F \
C(blended_segment) 687.531217 2.0 0.315852
C(EX_single_segment) 4229.398706 2.0 1.942987
C(blended_segment):C(EX_single_segment) 4849.562524 4.0 1.113945
Residual 88158.417341 81.0 NaN
PR(>F)
C(blended_segment) 0.730061
C(EX_single_segment) 0.149895
C(blended_segment):C(EX_single_segment) 0.355726
Residual NaN
Tukey's HSD test for blended_segment:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間 近い -4.4821 0.8627 -25.1109 16.1466 False
中間 遠い 6.9929 0.7065 -13.9543 27.94 False
近い 遠い 11.475 0.3714 -8.7837 31.7337 False
-----------------------------------------------------
Tukey's HSD test for EX_single_segment:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
====================================================
group1 group2 meandiff p-adj lower upper reject
----------------------------------------------------
中間 近い 1.1863 0.988 -17.9358 20.3083 False
中間 遠い 18.6355 0.095 -2.4909 39.762 False
近い 遠い 17.4493 0.129 -3.806 38.7045 False
----------------------------------------------------
Tukey's HSD test for interaction groups:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間_中間 中間_近い -11.7417 0.9962 -57.7751 34.2917 False
中間_中間 中間_遠い -16.675 0.9931 -76.6184 43.2684 False
中間_中間 近い_中間 -18.7171 0.914 -63.033 25.5988 False
中間_中間 近い_近い -19.0 0.964 -71.5738 33.5738 False
中間_中間 近い_遠い 13.525 0.9984 -46.4184 73.4684 False
中間_中間 遠い_中間 -15.875 0.9906 -70.2941 38.5441 False
中間_中間 遠い_近い -8.575 0.9998 -58.4509 41.3009 False
中間_中間 遠い_遠い 9.8942 0.9991 -37.3548 57.1432 False
中間_近い 中間_遠い -4.9333 1.0 -59.2314 49.3647 False
中間_近い 近い_中間 -6.9754 0.9995 -43.293 29.3421 False
中間_近い 近い_近い -7.2583 0.9999 -53.2917 38.7751 False
中間_近い 近い_遠い 25.2667 0.8601 -29.0314 79.5647 False
中間_近い 遠い_中間 -4.1333 1.0 -52.2634 43.9967 False
中間_近い 遠い_近い 3.1667 1.0 -39.7597 46.093 False
中間_近い 遠い_遠い 21.6359 0.726 -18.208 61.4798 False
中間_遠い 近い_中間 -2.0421 1.0 -54.8919 50.8077 False
中間_遠い 近い_近い -2.325 1.0 -62.2684 57.6184 False
中間_遠い 近い_遠い 30.2 0.8756 -36.3012 96.7012 False
中間_遠い 遠い_中間 0.8 1.0 -60.7682 62.3682 False
中間_遠い 遠い_近い 8.1 1.0 -49.4917 65.6917 False
中間_遠い 遠い_遠い 26.5692 0.8379 -28.7631 81.9016 False
近い_中間 近い_近い -0.2829 1.0 -44.5988 44.033 False
近い_中間 近い_遠い 32.2421 0.5857 -20.6077 85.0919 False
近い_中間 遠い_中間 2.8421 1.0 -43.648 49.3322 False
近い_中間 遠い_近い 10.1421 0.9969 -30.9371 51.2213 False
近い_中間 遠い_遠い 28.6113 0.2932 -9.2352 66.4579 False
近い_近い 近い_遠い 32.525 0.7268 -27.4184 92.4684 False
近い_近い 遠い_中間 3.125 1.0 -51.2941 57.5441 False
近い_近い 遠い_近い 10.425 0.9991 -39.4509 60.3009 False
近い_近い 遠い_遠い 28.8942 0.5825 -18.3548 76.1432 False
近い_遠い 遠い_中間 -29.4 0.842 -90.9682 32.1682 False
近い_遠い 遠い_近い -22.1 0.949 -79.6917 35.4917 False
近い_遠い 遠い_遠い -3.6308 1.0 -58.9631 51.7016 False
遠い_中間 遠い_近い 7.3 1.0 -44.5173 59.1173 False
遠い_中間 遠い_遠い 25.7692 0.7648 -23.5248 75.0632 False
遠い_近い 遠い_遠い 18.4692 0.9189 -25.7582 62.6967 False
-----------------------------------------------------
==================================================
EX - believability グループ平均:
EX_single_segment 近い 中間 遠い
blended_segment
近い -4.875000 -7.894737 24.400000
中間 -3.666667 15.625000 -16.200000
遠い -4.000000 -11.857143 23.153846
EX - believability 二元配置分散分析結果:
sum_sq df F \
C(blended_segment) 168.177584 2.0 0.104446
C(EX_single_segment) 4940.012912 2.0 3.067982
C(blended_segment):C(EX_single_segment) 9790.828818 4.0 3.040284
Residual 65212.422258 81.0 NaN
PR(>F)
C(blended_segment) 0.900944
C(EX_single_segment) 0.051957
C(blended_segment):C(EX_single_segment) 0.021780
Residual NaN
Tukey's HSD test for blended_segment:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間 近い -1.7009 0.9744 -20.4054 17.0036 False
中間 遠い 6.3262 0.7076 -12.6671 25.3194 False
近い 遠い 8.0271 0.5526 -10.3419 26.3961 False
-----------------------------------------------------
Tukey's HSD test for EX_single_segment:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間 近い -0.8841 0.9917 -18.0119 16.2437 False
中間 遠い 18.046 0.0649 -0.8772 36.9692 False
近い 遠い 18.9302 0.0517 -0.1084 37.9687 False
-----------------------------------------------------
Tukey's HSD test for interaction groups:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間_中間 中間_近い -19.2917 0.8266 -58.8836 20.3002 False
中間_中間 中間_遠い -31.825 0.57 -83.3805 19.7305 False
中間_中間 近い_中間 -23.5197 0.5705 -61.6345 14.595 False
中間_中間 近い_近い -20.5 0.8767 -65.7171 24.7171 False
中間_中間 近い_遠い 8.775 0.9998 -42.7805 60.3305 False
中間_中間 遠い_中間 -27.4821 0.6349 -74.2863 19.322 False
中間_中間 遠い_近い -19.625 0.8711 -62.5217 23.2717 False
中間_中間 遠い_遠い 7.5288 0.9996 -33.1086 48.1662 False
中間_近い 中間_遠い -12.5333 0.9946 -59.2334 34.1667 False
中間_近い 近い_中間 -4.2281 1.0 -35.4637 27.0075 False
中間_近い 近い_近い -1.2083 1.0 -40.8002 38.3836 False
中間_近い 近い_遠い 28.0667 0.6053 -18.6334 74.7667 False
中間_近い 遠い_中間 -8.1905 0.9994 -49.5856 33.2047 False
中間_近い 遠い_近い -0.3333 1.0 -37.253 36.5863 False
中間_近い 遠い_遠い 26.8205 0.2502 -7.4479 61.089 False
中間_遠い 近い_中間 8.3053 0.9997 -37.1492 53.7597 False
中間_遠い 近い_近い 11.325 0.9987 -40.2305 62.8805 False
中間_遠い 近い_遠い 40.6 0.3769 -16.5956 97.7956 False
中間_遠い 遠い_中間 4.3429 1.0 -48.61 57.2957 False
中間_遠い 遠い_近い 12.2 0.997 -37.3329 61.7329 False
中間_遠い 遠い_遠い 39.3538 0.1885 -8.2358 86.9435 False
近い_中間 近い_近い 3.0197 1.0 -35.095 41.1345 False
近い_中間 近い_遠い 32.2947 0.3757 -13.1597 77.7492 False
近い_中間 遠い_中間 -3.9624 1.0 -43.9471 36.0223 False
近い_中間 遠い_近い 3.8947 1.0 -31.4362 39.2257 False
近い_中間 遠い_遠い 31.0486 0.0735 -1.502 63.5992 False
近い_近い 近い_遠い 29.275 0.6756 -22.2805 80.8305 False
近い_近い 遠い_中間 -6.9821 0.9999 -53.7863 39.822 False
近い_近い 遠い_近い 0.875 1.0 -42.0217 43.7717 False
近い_近い 遠い_遠い 28.0288 0.4167 -12.6086 68.6662 False
近い_遠い 遠い_中間 -36.2571 0.4269 -89.21 16.6957 False
近い_遠い 遠い_近い -28.4 0.6641 -77.9329 21.1329 False
近い_遠い 遠い_遠い -1.2462 1.0 -48.8358 46.3435 False
遠い_中間 遠い_近い 7.8571 0.9997 -36.7093 52.4236 False
遠い_中間 遠い_遠い 35.011 0.1899 -7.3852 77.4072 False
遠い_近い 遠い_遠い 27.1538 0.3692 -10.8848 65.1925 False
-----------------------------------------------------
==================================================
EX - overall_liking グループ平均:
EX_single_segment 近い 中間 遠い
blended_segment
近い -12.750000 -3.684211 26.800000
中間 -1.133333 10.000000 -20.200000
遠い 14.500000 -13.857143 21.384615
EX - overall_liking 二元配置分散分析結果:
sum_sq df F \
C(blended_segment) 1434.695240 2.0 0.662232
C(EX_single_segment) 2243.828843 2.0 1.035715
C(blended_segment):C(EX_single_segment) 11517.568733 4.0 2.658162
Residual 87741.372662 81.0 NaN
PR(>F)
C(blended_segment) 0.518468
C(EX_single_segment) 0.359625
C(blended_segment):C(EX_single_segment) 0.038587
Residual NaN
Tukey's HSD test for blended_segment:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間 近い 0.1696 0.9998 -20.9067 21.246 False
中間 遠い 12.2238 0.3653 -9.1778 33.6255 False
近い 遠い 12.0542 0.3512 -8.6441 32.7524 False
-----------------------------------------------------
Tukey's HSD test for EX_single_segment:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間 近い 3.3467 0.9146 -16.4766 23.17 False
中間 遠い 16.0806 0.1924 -5.8207 37.9818 False
近い 遠い 12.7339 0.3568 -9.3009 34.7686 False
-----------------------------------------------------
Tukey's HSD test for interaction groups:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=======================================================
group1 group2 meandiff p-adj lower upper reject
-------------------------------------------------------
中間_中間 中間_近い -11.1333 0.9973 -57.0577 34.791 False
中間_中間 中間_遠い -30.2 0.7968 -90.0014 29.6014 False
中間_中間 近い_中間 -13.6842 0.9861 -57.8952 30.5268 False
中間_中間 近い_近い -22.75 0.9012 -75.1993 29.6993 False
中間_中間 近い_遠い 16.8 0.9926 -43.0014 76.6014 False
中間_中間 遠い_中間 -23.8571 0.8944 -78.1474 30.4331 False
中間_中間 遠い_近い 4.5 1.0 -45.2578 54.2578 False
中間_中間 遠い_遠い 11.3846 0.9974 -35.7525 58.5217 False
中間_近い 中間_遠い -19.0667 0.9692 -73.2361 35.1028 False
中間_近い 近い_中間 -2.5509 1.0 -38.7824 33.6807 False
中間_近い 近い_近い -11.6167 0.9964 -57.541 34.3077 False
中間_近い 近い_遠い 27.9333 0.7779 -26.2361 82.1028 False
中間_近い 遠い_中間 -12.7238 0.995 -60.7399 35.2923 False
中間_近い 遠い_近い 15.6333 0.9618 -27.1914 58.458 False
中間_近い 遠い_遠い 22.5179 0.6784 -17.2316 62.2674 False
中間_遠い 近い_中間 16.5158 0.985 -36.2089 69.2404 False
中間_遠い 近い_近い 7.45 1.0 -52.3514 67.2514 False
中間_遠い 近い_遠い 47.0 0.3797 -19.3437 113.3437 False
中間_遠い 遠い_中間 6.3429 1.0 -55.0795 67.7652 False
中間_遠い 遠い_近い 34.7 0.5989 -22.7554 92.1554 False
中間_遠い 遠い_遠い 41.5846 0.2977 -13.6167 96.7859 False
近い_中間 近い_近い -9.0658 0.9992 -53.2768 35.1452 False
近い_中間 近い_遠い 30.4842 0.654 -22.2404 83.2089 False
近い_中間 遠い_中間 -10.1729 0.9987 -56.5529 36.2071 False
近い_中間 遠い_近い 18.1842 0.8892 -22.7977 59.1661 False
近い_中間 遠い_遠い 25.0688 0.4699 -12.6881 62.8257 False
近い_近い 近い_遠い 39.55 0.4754 -20.2514 99.3514 False
近い_近い 遠い_中間 -1.1071 1.0 -55.3974 53.1831 False
近い_近い 遠い_近い 27.25 0.7168 -22.5078 77.0078 False
近い_近い 遠い_遠い 34.1346 0.3498 -13.0025 81.2717 False
近い_遠い 遠い_中間 -40.6571 0.4742 -102.0795 20.7652 False
近い_遠い 遠い_近い -12.3 0.9989 -69.7554 45.1554 False
近い_遠い 遠い_遠い -5.4154 1.0 -60.6167 49.7859 False
遠い_中間 遠い_近い 28.3571 0.715 -23.3375 80.0518 False
遠い_中間 遠い_遠い 35.2418 0.3639 -13.9355 84.419 False
遠い_近い 遠い_遠い 6.8846 0.9999 -37.2381 51.0073 False
-------------------------------------------------------
==================================================
EX - persuasiveness グループ平均:
EX_single_segment 近い 中間 遠い
blended_segment
近い -7.250000 -9.157895 24.600000
中間 0.333333 6.125000 -23.200000
遠い -3.000000 -5.000000 22.461538
EX - persuasiveness 二元配置分散分析結果:
sum_sq df F \
C(blended_segment) 743.896734 2.0 0.388719
C(EX_single_segment) 3366.395189 2.0 1.759089
C(blended_segment):C(EX_single_segment) 9263.939095 4.0 2.420407
Residual 77505.465418 81.0 NaN
PR(>F)
C(blended_segment) 0.679183
C(EX_single_segment) 0.178716
C(blended_segment):C(EX_single_segment) 0.054998
Residual NaN
Tukey's HSD test for blended_segment:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間 近い -1.192 0.9888 -21.0531 18.6692 False
中間 遠い 9.781 0.4823 -10.3868 29.9487 False
近い 遠い 10.9729 0.3763 -8.5319 30.4778 False
-----------------------------------------------------
Tukey's HSD test for EX_single_segment:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間 近い 2.1907 0.9569 -16.2897 20.6712 False
中間 遠い 17.7059 0.1026 -2.7117 38.1235 False
近い 遠い 15.5152 0.1753 -5.0269 36.0572 False
-----------------------------------------------------
Tukey's HSD test for interaction groups:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
======================================================
group1 group2 meandiff p-adj lower upper reject
------------------------------------------------------
中間_中間 中間_近い -5.7917 1.0 -48.9542 37.3709 False
中間_中間 中間_遠い -29.325 0.7667 -85.5301 26.8801 False
中間_中間 近い_中間 -15.2829 0.9601 -56.8351 26.2693 False
中間_中間 近い_近い -13.375 0.9942 -62.6701 35.9201 False
中間_中間 近い_遠い 18.475 0.9797 -37.7301 74.6801 False
中間_中間 遠い_中間 -11.125 0.9987 -62.1503 39.9003 False
中間_中間 遠い_近い -9.125 0.9994 -55.8905 37.6405 False
中間_中間 遠い_遠い 16.3365 0.9595 -27.9658 60.6389 False
中間_近い 中間_遠い -23.5333 0.8645 -74.4451 27.3784 False
中間_近い 近い_中間 -9.4912 0.993 -43.5439 24.5614 False
中間_近い 近い_近い -7.5833 0.9997 -50.7459 35.5792 False
中間_近い 近い_遠い 24.2667 0.8433 -26.6451 75.1784 False
中間_近い 遠い_中間 -5.3333 1.0 -50.4618 39.7951 False
中間_近い 遠い_近い -3.3333 1.0 -43.5826 36.916 False
中間_近い 遠い_遠い 22.1282 0.6239 -15.2308 59.4872 False
中間_遠い 近い_中間 14.0421 0.9922 -35.5118 63.596 False
中間_遠い 近い_近い 15.95 0.9921 -40.2551 72.1551 False
中間_遠い 近い_遠い 47.8 0.2756 -14.5539 110.1539 False
中間_遠い 遠い_中間 18.2 0.9844 -39.5285 75.9285 False
中間_遠い 遠い_近い 20.2 0.9559 -33.8001 74.2001 False
中間_遠い 遠い_遠い 45.6615 0.1299 -6.2201 97.5432 False
近い_中間 近い_近い 1.9079 1.0 -39.6443 43.4601 False
近い_中間 近い_遠い 33.7579 0.434 -15.796 83.3118 False
近い_中間 遠い_中間 4.1579 1.0 -39.4329 47.7487 False
近い_中間 遠い_近い 6.1579 0.9999 -32.3594 44.6752 False
近い_中間 遠い_遠い 31.6194 0.1199 -3.8668 67.1057 False
近い_近い 近い_遠い 31.85 0.678 -24.3551 88.0551 False
近い_近い 遠い_中間 2.25 1.0 -48.7753 53.2753 False
近い_近い 遠い_近い 4.25 1.0 -42.5155 51.0155 False
近い_近い 遠い_遠い 29.7115 0.4559 -14.5908 74.0139 False
近い_遠い 遠い_中間 -29.6 0.7832 -87.3285 28.1285 False
近い_遠い 遠い_近い -27.6 0.7861 -81.6001 26.4001 False
近い_遠い 遠い_遠い -2.1385 1.0 -54.0201 49.7432 False
遠い_中間 遠い_近い 2.0 1.0 -46.5858 50.5858 False
遠い_中間 遠い_遠い 27.4615 0.62 -18.7583 73.6814 False
遠い_近い 遠い_遠い 25.4615 0.5772 -16.0077 66.9308 False
------------------------------------------------------
==================================================
EX - interest グループ平均:
EX_single_segment 近い 中間 遠い
blended_segment
近い -10.000000 -9.421053 25.600000
中間 1.266667 12.375000 -8.400000
遠い 6.300000 -2.714286 23.846154
EX - interest 二元配置分散分析結果:
sum_sq df F \
C(blended_segment) 1783.649118 2.0 0.805568
C(EX_single_segment) 3970.355028 2.0 1.793174
C(blended_segment):C(EX_single_segment) 6315.817216 4.0 1.426240
Residual 89673.060791 81.0 NaN
PR(>F)
C(blended_segment) 0.450381
C(EX_single_segment) 0.172975
C(blended_segment):C(EX_single_segment) 0.232763
Residual NaN
Tukey's HSD test for blended_segment:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間 近い -6.808 0.7186 -27.7235 14.1074 False
中間 遠い 9.0857 0.5663 -12.1526 30.324 False
近い 遠い 15.8938 0.1612 -4.6465 36.434 False
-----------------------------------------------------
Tukey's HSD test for EX_single_segment:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間 近い 2.9724 0.9301 -16.5613 22.506 False
中間 遠い 20.1292 0.0727 -1.4521 41.7104 False
近い 遠い 17.1568 0.1494 -4.556 38.8696 False
-----------------------------------------------------
Tukey's HSD test for interaction groups:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
======================================================
group1 group2 meandiff p-adj lower upper reject
------------------------------------------------------
中間_中間 中間_近い -11.1083 0.9975 -57.5355 35.3188 False
中間_中間 中間_遠い -20.775 0.9734 -81.2311 39.6811 False
中間_中間 近い_中間 -21.7961 0.826 -66.491 22.8989 False
中間_中間 近い_近い -22.375 0.9144 -75.3985 30.6485 False
中間_中間 近い_遠い 13.225 0.9987 -47.2311 73.6811 False
中間_中間 遠い_中間 -15.0893 0.9936 -69.9739 39.7953 False
中間_中間 遠い_近い -6.075 1.0 -56.3775 44.2275 False
中間_中間 遠い_遠い 11.4712 0.9974 -36.182 59.1243 False
中間_近い 中間_遠い -9.6667 0.9997 -64.4291 45.0958 False
中間_近い 近い_中間 -10.6877 0.9905 -47.3159 25.9405 False
中間_近い 近い_近い -11.2667 0.9973 -57.6938 35.1605 False
中間_近い 近い_遠い 24.3333 0.8884 -30.4291 79.0958 False
中間_近い 遠い_中間 -3.981 1.0 -52.5227 44.5608 False
中間_近い 遠い_近い 5.0333 1.0 -38.2602 48.3269 False
中間_近い 遠い_遠い 22.5795 0.6879 -17.6052 62.7642 False
中間_遠い 近い_中間 -1.0211 1.0 -54.3229 52.2808 False
中間_遠い 近い_近い -1.6 1.0 -62.0561 58.8561 False
中間_遠い 近い_遠い 34.0 0.7935 -33.0701 101.0701 False
中間_遠い 遠い_中間 5.6857 1.0 -56.4091 67.7805 False
中間_遠い 遠い_近い 14.7 0.9964 -43.3844 72.7844 False
中間_遠い 遠い_遠い 32.2462 0.6547 -23.5595 88.0518 False
近い_中間 近い_近い -0.5789 1.0 -45.2739 44.116 False
近い_中間 近い_遠い 35.0211 0.4846 -18.2808 88.3229 False
近い_中間 遠い_中間 6.7068 0.9999 -40.181 53.5945 False
近い_中間 遠い_近い 15.7211 0.9522 -25.7095 57.1516 False
近い_中間 遠い_遠い 33.2672 0.1383 -4.9031 71.4375 False
近い_近い 近い_遠い 35.6 0.6313 -24.8561 96.0561 False
近い_近い 遠い_中間 7.2857 1.0 -47.5989 62.1703 False
近い_近い 遠い_近い 16.3 0.9815 -34.0025 66.6025 False
近い_近い 遠い_遠い 33.8462 0.3761 -13.807 81.4993 False
近い_遠い 遠い_中間 -28.3143 0.8731 -90.4091 33.7805 False
近い_遠い 遠い_近い -19.3 0.9783 -77.3844 38.7844 False
近い_遠い 遠い_遠い -1.7538 1.0 -57.5595 54.0518 False
遠い_中間 遠い_近い 9.0143 0.9998 -43.2463 61.2749 False
遠い_中間 遠い_遠い 26.5604 0.7431 -23.1552 76.2761 False
遠い_近い 遠い_遠い 17.5462 0.9414 -27.0596 62.1519 False
------------------------------------------------------
==================================================
EX - click_likelihood グループ平均:
EX_single_segment 近い 中間 遠い
blended_segment
近い -8.750000 -6.421053 25.600000
中間 0.866667 12.250000 -6.400000
遠い 1.200000 -6.428571 22.384615
EX - click_likelihood 二元配置分散分析結果:
sum_sq df F \
C(blended_segment) 553.740073 2.0 0.228650
C(EX_single_segment) 4697.135916 2.0 1.939537
C(blended_segment):C(EX_single_segment) 5640.015105 4.0 1.164435
Residual 98082.156121 81.0 NaN
PR(>F)
C(blended_segment) 0.796119
C(EX_single_segment) 0.150389
C(blended_segment):C(EX_single_segment) 0.332697
Residual NaN
Tukey's HSD test for blended_segment:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間 近い -4.8214 0.8579 -26.604 16.9611 False
中間 遠い 5.7786 0.808 -16.3402 27.8974 False
近い 遠い 10.6 0.4673 -10.7918 31.9918 False
-----------------------------------------------------
Tukey's HSD test for EX_single_segment:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間 近い 0.6658 0.9966 -19.5071 20.8386 False
中間 遠い 18.8555 0.1141 -3.4319 41.1429 False
近い 遠い 18.1897 0.1352 -4.2336 40.613 False
-----------------------------------------------------
Tukey's HSD test for interaction groups:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
======================================================
group1 group2 meandiff p-adj lower upper reject
------------------------------------------------------
中間_中間 中間_近い -11.3833 0.9979 -59.9386 37.1719 False
中間_中間 中間_遠い -18.65 0.9898 -81.8773 44.5773 False
中間_中間 近い_中間 -18.6711 0.9363 -65.4147 28.0726 False
中間_中間 近い_近い -21.0 0.9527 -76.454 34.454 False
中間_中間 近い_遠い 13.35 0.999 -49.8773 76.5773 False
中間_中間 遠い_中間 -18.6786 0.981 -76.0789 38.7218 False
中間_中間 遠い_近い -11.05 0.999 -63.6583 41.5583 False
中間_中間 遠い_遠い 10.1346 0.9992 -39.7028 59.9721 False
中間_近い 中間_遠い -7.2667 1.0 -64.5393 50.006 False
中間_近い 近い_中間 -7.2877 0.9995 -45.5949 31.0194 False
中間_近い 近い_近い -9.6167 0.9994 -58.1719 38.9386 False
中間_近い 近い_遠い 24.7333 0.9034 -32.5393 82.006 False
中間_近い 遠い_中間 -7.2952 0.9999 -58.062 43.4715 False
中間_近い 遠い_近い 0.3333 1.0 -44.9447 45.6113 False
中間_近い 遠い_遠い 21.5179 0.7845 -20.5087 63.5446 False
中間_遠い 近い_中間 -0.0211 1.0 -55.7661 55.724 False
中間_遠い 近い_近い -2.35 1.0 -65.5773 60.8773 False
中間_遠い 近い_遠い 32.0 0.8728 -38.1444 102.1444 False
中間_遠い 遠い_中間 -0.0286 1.0 -64.9696 64.9125 False
中間_遠い 遠い_近い 7.6 1.0 -53.1468 68.3468 False
中間_遠い 遠い_遠い 28.7846 0.8169 -29.579 87.1482 False
近い_中間 近い_近い -2.3289 1.0 -49.0726 44.4147 False
近い_中間 近い_遠い 32.0211 0.6619 -23.724 87.7661 False
近い_中間 遠い_中間 -0.0075 1.0 -49.0445 49.0294 False
近い_中間 遠い_近い 7.6211 0.9997 -35.7086 50.9507 False
近い_中間 遠い_遠い 28.8057 0.3546 -11.1142 68.7256 False
近い_近い 近い_遠い 34.35 0.7255 -28.8773 97.5773 False
近い_近い 遠い_中間 2.3214 1.0 -55.0789 59.7218 False
近い_近い 遠い_近い 9.95 0.9995 -42.6583 62.5583 False
近い_近い 遠い_遠い 31.1346 0.554 -18.7028 80.9721 False
近い_遠い 遠い_中間 -32.0286 0.8169 -96.9696 32.9125 False
近い_遠い 遠い_近い -24.4 0.9343 -85.1468 36.3468 False
近い_遠い 遠い_遠い -3.2154 1.0 -61.579 55.1482 False
遠い_中間 遠い_近い 7.6286 1.0 -47.0275 62.2846 False
遠い_中間 遠い_遠い 28.8132 0.7037 -23.1813 80.8076 False
遠い_近い 遠い_遠い 21.1846 0.8757 -25.4657 67.835 False
------------------------------------------------------
==================================================
OP - preference グループ平均:
OP_single_segment 近い 中間 遠い
blended_segment
近い 0.615385 -7.562500 -20.333333
中間 -8.583333 -6.833333 -12.700000
遠い -23.200000 -0.666667 7.882353
OP - preference 二元配置分散分析結果:
sum_sq df F \
C(blended_segment) 545.177888 2.0 0.266845
C(OP_single_segment) 870.980983 2.0 0.426314
C(blended_segment):C(OP_single_segment) 6604.105364 4.0 1.616236
Residual 82743.562462 81.0 NaN
PR(>F)
C(blended_segment) 0.766462
C(OP_single_segment) 0.654368
C(blended_segment):C(OP_single_segment) 0.178125
Residual NaN
Tukey's HSD test for blended_segment:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間 近い 4.2411 0.8672 -15.6292 24.1113 False
中間 遠い 6.3452 0.7345 -13.8318 26.5222 False
近い 遠い 2.1042 0.9642 -17.4097 21.618 False
-----------------------------------------------------
Tukey's HSD test for OP_single_segment:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間 近い -2.7829 0.9416 -22.8538 17.2881 False
中間 遠い 4.76 0.8484 -15.9962 25.5162 False
近い 遠い 7.5429 0.6146 -11.5275 26.6132 False
-----------------------------------------------------
Tukey's HSD test for interaction groups:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間_中間 中間_近い -1.75 1.0 -52.6837 49.1837 False
中間_中間 中間_遠い -5.8667 1.0 -58.4707 46.7374 False
中間_中間 近い_中間 -0.7292 1.0 -49.4944 48.0361 False
中間_中間 近い_近い 7.4487 0.9999 -42.8277 57.7251 False
中間_中間 近い_遠い -13.5 0.9996 -85.5311 58.5311 False
中間_中間 遠い_中間 6.1667 1.0 -65.8644 78.1977 False
中間_中間 遠い_近い -16.3667 0.9857 -68.9707 36.2374 False
中間_中間 遠い_遠い 14.7157 0.9876 -33.6568 63.0882 False
中間_近い 中間_遠い -4.1167 1.0 -47.7336 39.5003 False
中間_近い 近い_中間 1.0208 1.0 -37.8804 39.9221 False
中間_近い 近い_近い 9.1987 0.9984 -31.5808 49.9783 False
中間_近い 近い_遠い -11.75 0.9997 -77.5051 54.0051 False
中間_近い 遠い_中間 7.9167 1.0 -57.8384 73.6717 False
中間_近い 遠い_近い -14.6167 0.9771 -58.2336 29.0003 False
中間_近い 遠い_遠い 16.4657 0.907 -21.9421 54.8734 False
中間_遠い 近い_中間 5.1375 1.0 -35.9265 46.2015 False
中間_遠い 近い_近い 13.3154 0.9858 -29.5323 56.163 False
中間_遠い 近い_遠い -7.6333 1.0 -74.6906 59.4239 False
中間_遠い 遠い_中間 12.0333 0.9997 -55.0239 79.0906 False
中間_遠い 遠い_近い -10.5 0.9981 -56.0564 35.0564 False
中間_遠い 遠い_遠い 20.5824 0.7934 -20.0145 61.1792 False
近い_中間 近い_近い 8.1779 0.9989 -29.8588 46.2145 False
近い_中間 近い_遠い -12.7708 0.9993 -76.8609 51.3193 False
近い_中間 遠い_中間 6.8958 1.0 -57.1943 70.9859 False
近い_中間 遠い_近い -15.6375 0.9512 -56.7015 25.4265 False
近い_中間 遠い_遠い 15.4449 0.8994 -20.0371 50.9268 False
近い_近い 近い_遠い -20.9487 0.9825 -86.196 44.2986 False
近い_近い 遠い_中間 -1.2821 1.0 -66.5293 63.9652 False
近い_近い 遠い_近い -23.8154 0.7003 -66.663 19.0323 False
近い_近い 遠い_遠い 7.267 0.9995 -30.2648 44.7988 False
近い_遠い 遠い_中間 19.6667 0.9977 -63.5076 102.841 False
近い_遠い 遠い_近い -2.8667 1.0 -69.9239 64.1906 False
近い_遠い 遠い_遠い 28.2157 0.8909 -35.5761 92.0075 False
遠い_中間 遠い_近い -22.5333 0.9768 -89.5906 44.5239 False
遠い_中間 遠い_遠い 8.549 1.0 -55.2428 72.3408 False
遠い_近い 遠い_遠い 31.0824 0.2771 -9.5145 71.6792 False
-----------------------------------------------------
==================================================
OP - believability グループ平均:
OP_single_segment 近い 中間 遠い
blended_segment
近い 3.384615 -4.250000 -26.333333
中間 -5.083333 1.333333 -8.800000
遠い -20.300000 -13.000000 6.294118
OP - believability 二元配置分散分析結果:
sum_sq df F \
C(blended_segment) 140.803890 2.0 0.103415
C(OP_single_segment) 386.634069 2.0 0.283969
C(blended_segment):C(OP_single_segment) 6879.075965 4.0 2.526218
Residual 55142.223002 81.0 NaN
PR(>F)
C(blended_segment) 0.901871
C(OP_single_segment) 0.753536
C(blended_segment):C(OP_single_segment) 0.046983
Residual NaN
Tukey's HSD test for blended_segment:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間 近い 1.817 0.9628 -14.7093 18.3433 False
中間 遠い 0.5357 0.9968 -16.2457 17.3171 False
近い 遠い -1.2812 0.9807 -17.5111 14.9486 False
-----------------------------------------------------
Tukey's HSD test for OP_single_segment:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間 近い -2.3257 0.941 -19.0162 14.3648 False
中間 遠い 1.96 0.9604 -15.3003 19.2203 False
近い 遠い 4.2857 0.796 -11.5727 20.1441 False
-----------------------------------------------------
Tukey's HSD test for interaction groups:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間_中間 中間_近い -6.4167 0.9999 -47.9962 35.1629 False
中間_中間 中間_遠い -10.1333 0.9978 -53.0765 32.8099 False
中間_中間 近い_中間 -5.5833 1.0 -45.3927 34.2261 False
中間_中間 近い_近い 2.0513 1.0 -38.9917 43.0943 False
中間_中間 近い_遠い -27.6667 0.8525 -86.469 31.1357 False
中間_中間 遠い_中間 -14.3333 0.9972 -73.1357 44.469 False
中間_中間 遠い_近い -21.6333 0.799 -64.5765 21.3099 False
中間_中間 遠い_遠い 4.9608 1.0 -34.528 44.4496 False
中間_近い 中間_遠い -3.7167 1.0 -39.3233 31.8899 False
中間_近い 近い_中間 0.8333 1.0 -30.9236 32.5902 False
中間_近い 近い_近い 8.4679 0.9962 -24.8223 41.7582 False
中間_近い 近い_遠い -21.25 0.9393 -74.929 32.429 False
中間_近い 遠い_中間 -7.9167 0.9999 -61.5956 45.7623 False
中間_近い 遠い_近い -15.2167 0.9085 -50.8233 20.3899 False
中間_近い 遠い_遠い 11.3775 0.9631 -19.9766 42.7315 False
中間_遠い 近い_中間 4.55 1.0 -28.9725 38.0725 False
中間_遠い 近い_近い 12.1846 0.9711 -22.794 47.1632 False
中間_遠い 近い_遠い -17.5333 0.9828 -72.2754 37.2087 False
中間_遠い 遠い_中間 -4.2 1.0 -58.942 50.542 False
中間_遠い 遠い_近い -11.5 0.9862 -48.6899 25.6899 False
中間_遠い 遠い_遠い 15.0941 0.8739 -18.047 48.2352 False
近い_中間 近い_近い 7.6346 0.997 -23.4165 38.6857 False
近い_中間 近い_遠い -22.0833 0.9142 -74.4031 30.2365 False
近い_中間 遠い_中間 -8.75 0.9998 -61.0698 43.5698 False
近い_中間 遠い_近い -16.05 0.84 -49.5725 17.4725 False
近い_中間 遠い_遠い 10.5441 0.9624 -18.4215 39.5097 False
近い_近い 近い_遠い -29.7179 0.696 -82.9824 23.5465 False
近い_近い 遠い_中間 -16.3846 0.9867 -69.6491 36.8798 False
近い_近い 遠い_近い -23.6846 0.4425 -58.6632 11.294 False
近い_近い 遠い_遠い 2.9095 1.0 -27.7295 33.5485 False
近い_遠い 遠い_中間 13.3333 0.9994 -54.5658 81.2325 False
近い_遠い 遠い_近い 6.0333 1.0 -48.7087 60.7754 False
近い_遠い 遠い_遠い 32.6275 0.55 -19.4488 84.7037 False
遠い_中間 遠い_近い -7.3 1.0 -62.042 47.442 False
遠い_中間 遠い_遠い 19.2941 0.9583 -32.7821 71.3704 False
遠い_近い 遠い_遠い 26.5941 0.2211 -6.547 59.7352 False
-----------------------------------------------------
==================================================
OP - overall_liking グループ平均:
OP_single_segment 近い 中間 遠い
blended_segment
近い 1.692308 -4.562500 9.333333
中間 -18.750000 -0.666667 -17.900000
遠い -18.500000 3.666667 -0.941176
OP - overall_liking 二元配置分散分析結果:
sum_sq df F \
C(blended_segment) 2708.926089 2.0 1.259604
C(OP_single_segment) 949.049125 2.0 0.441292
C(blended_segment):C(OP_single_segment) 3420.978861 4.0 0.795348
Residual 87099.964574 81.0 NaN
PR(>F)
C(blended_segment) 0.289265
C(OP_single_segment) 0.644742
C(blended_segment):C(OP_single_segment) 0.531632
Residual NaN
Tukey's HSD test for blended_segment:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間 近い 13.8527 0.2301 -6.1549 33.8603 False
中間 遠い 8.2381 0.5997 -12.0783 28.5545 False
近い 遠い -5.6146 0.775 -25.2633 14.0341 False
-----------------------------------------------------
Tukey's HSD test for OP_single_segment:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間 近い -8.4457 0.5881 -28.8858 11.9944 False
中間 遠い -2.9267 0.9417 -24.0646 18.2113 False
近い 遠い 5.519 0.7771 -13.902 24.9401 False
-----------------------------------------------------
Tukey's HSD test for interaction groups:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間_中間 中間_近い -18.0833 0.9722 -70.3406 34.1739 False
中間_中間 中間_遠い -17.2333 0.9831 -71.2044 36.7377 False
中間_中間 近い_中間 -3.8958 1.0 -53.9284 46.1367 False
中間_中間 近い_近い 2.359 1.0 -49.224 53.9419 False
中間_中間 近い_遠い 10.0 1.0 -63.9029 83.9029 False
中間_中間 遠い_中間 4.3333 1.0 -69.5696 78.2363 False
中間_中間 遠い_近い -17.8333 0.9791 -71.8044 36.1377 False
中間_中間 遠い_遠い -0.2745 1.0 -49.9041 49.3551 False
中間_近い 中間_遠い 0.85 1.0 -43.9005 45.6005 False
中間_近い 近い_中間 14.1875 0.9673 -25.7247 54.0997 False
中間_近い 近い_近い 20.4423 0.8245 -21.397 62.2816 False
中間_近い 近い_遠い 28.0833 0.9203 -39.3805 95.5472 False
中間_近い 遠い_中間 22.4167 0.9783 -45.0472 89.8805 False
中間_近い 遠い_近い 0.25 1.0 -44.5005 45.0005 False
中間_近い 遠い_遠い 17.8088 0.8786 -21.597 57.2147 False
中間_遠い 近い_中間 13.3375 0.984 -28.7937 55.4687 False
中間_遠い 近い_近い 19.5923 0.8867 -24.3688 63.5535 False
中間_遠い 近い_遠い 27.2333 0.9394 -41.5666 96.0332 False
中間_遠い 遠い_中間 21.5667 0.985 -47.2332 90.3666 False
中間_遠い 遠い_近い -0.6 1.0 -47.3403 46.1403 False
中間_遠い 遠い_遠い 16.9588 0.9292 -24.693 58.6107 False
近い_中間 近い_近い 6.2548 0.9999 -32.7703 45.2799 False
近い_中間 近い_遠い 13.8958 0.999 -51.8598 79.6515 False
近い_中間 遠い_中間 8.2292 1.0 -57.5265 73.9848 False
近い_中間 遠い_近い -13.9375 0.9789 -56.0687 28.1937 False
近い_中間 遠い_遠い 3.6213 1.0 -32.7827 40.0253 False
近い_近い 近い_遠い 7.641 1.0 -59.3019 74.5839 False
近い_近い 遠い_中間 1.9744 1.0 -64.9685 68.9172 False
近い_近い 遠い_近い -20.1923 0.8686 -64.1535 23.7688 False
近い_近い 遠い_遠い -2.6335 1.0 -41.1406 35.8737 False
近い_遠い 遠い_中間 -5.6667 1.0 -91.0024 79.6691 False
近い_遠い 遠い_近い -27.8333 0.9317 -96.6332 40.9666 False
近い_遠い 遠い_遠い -10.2745 0.9999 -75.7241 55.175 False
遠い_中間 遠い_近い -22.1667 0.9821 -90.9666 46.6332 False
遠い_中間 遠い_遠い -4.6078 1.0 -70.0574 60.8417 False
遠い_近い 遠い_遠い 17.5588 0.9148 -24.093 59.2107 False
-----------------------------------------------------
==================================================
OP - persuasiveness グループ平均:
OP_single_segment 近い 中間 遠い
blended_segment
近い -0.923077 -10.125000 -36.333333
中間 -15.750000 -0.666667 -16.100000
遠い -21.300000 1.333333 4.647059
OP - persuasiveness 二元配置分散分析結果:
sum_sq df F \
C(blended_segment) 922.004742 2.0 0.529824
C(OP_single_segment) 543.140635 2.0 0.312112
C(blended_segment):C(OP_single_segment) 8007.701257 4.0 2.300787
Residual 70478.472097 81.0 NaN
PR(>F)
C(blended_segment) 0.590735
C(OP_single_segment) 0.732776
C(blended_segment):C(OP_single_segment) 0.065684
Residual NaN
Tukey's HSD test for blended_segment:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間 近い 3.7991 0.8776 -14.7982 22.3964 False
中間 遠い 8.3095 0.5481 -10.5748 27.1939 False
近い 遠い 4.5104 0.8264 -13.7533 22.7741 False
-----------------------------------------------------
Tukey's HSD test for OP_single_segment:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間 近い -5.3486 0.778 -24.2128 13.5156 False
中間 遠い 0.1133 0.9999 -19.3949 19.6215 False
近い 遠い 5.4619 0.7484 -12.4618 23.3856 False
-----------------------------------------------------
Tukey's HSD test for interaction groups:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=======================================================
group1 group2 meandiff p-adj lower upper reject
-------------------------------------------------------
中間_中間 中間_近い -15.0833 0.9826 -62.0907 31.924 False
中間_中間 中間_遠い -15.4333 0.9836 -63.9823 33.1157 False
中間_中間 近い_中間 -9.4583 0.999 -54.4645 35.5478 False
中間_中間 近い_近い -0.2564 1.0 -46.6572 46.1444 False
中間_中間 近い_遠い -35.6667 0.7387 -102.1451 30.8118 False
中間_中間 遠い_中間 2.0 1.0 -64.4785 68.4785 False
中間_中間 遠い_近い -20.6333 0.9111 -69.1823 27.9157 False
中間_中間 遠い_遠い 5.3137 1.0 -39.3299 49.9574 False
中間_近い 中間_遠い -0.35 1.0 -40.6047 39.9047 False
中間_近い 近い_中間 5.625 0.9999 -30.2775 41.5275 False
中間_近い 近い_近い 14.8269 0.9409 -22.8091 52.4629 False
中間_近い 近い_遠い -20.5833 0.9754 -81.2696 40.1029 False
中間_近い 遠い_中間 17.0833 0.9925 -43.6029 77.7696 False
中間_近い 遠い_近い -5.55 1.0 -45.8047 34.7047 False
中間_近い 遠い_遠い 20.3971 0.6598 -15.05 55.8441 False
中間_遠い 近い_中間 5.975 0.9999 -31.9236 43.8736 False
中間_遠い 近い_近い 15.1769 0.949 -24.3678 54.7216 False
中間_遠い 近い_遠い -20.2333 0.9804 -82.1214 41.6547 False
中間_遠い 遠い_中間 17.4333 0.9925 -44.4547 79.3214 False
中間_遠い 遠い_近い -5.2 1.0 -47.2447 36.8447 False
中間_遠い 遠い_遠い 20.7471 0.7046 -16.7203 58.2144 False
近い_中間 近い_近い 9.2019 0.9954 -25.9026 44.3065 False
近い_中間 近い_遠い -26.2083 0.8899 -85.358 32.9413 False
近い_中間 遠い_中間 11.4583 0.9995 -47.6913 70.608 False
近い_中間 遠い_近い -11.175 0.9899 -49.0736 26.7236 False
近い_中間 遠い_遠い 14.7721 0.8797 -17.9747 47.5188 False
近い_近い 近い_遠い -35.4103 0.633 -95.6279 24.8074 False
近い_近い 遠い_中間 2.2564 1.0 -57.9612 62.474 False
近い_近い 遠い_近い -20.3769 0.7786 -59.9216 19.1678 False
近い_近い 遠い_遠い 5.5701 0.9999 -29.0685 40.2087 False
近い_遠い 遠い_中間 37.6667 0.8211 -39.0961 114.4294 False
近い_遠い 遠い_近い 15.0333 0.9973 -46.8547 76.9214 False
近い_遠い 遠い_遠い 40.9804 0.404 -17.8939 99.8547 False
遠い_中間 遠い_近い -22.6333 0.9614 -84.5214 39.2547 False
遠い_中間 遠い_遠い 3.3137 1.0 -55.5606 62.188 False
遠い_近い 遠い_遠い 25.9471 0.4111 -11.5203 63.4144 False
-------------------------------------------------------
==================================================
OP - interest グループ平均:
OP_single_segment 近い 中間 遠い
blended_segment
近い 1.076923 -9.437500 -14.666667
中間 -19.750000 -0.833333 -10.800000
遠い -17.100000 -2.000000 -1.941176
OP - interest 二元配置分散分析結果:
sum_sq df F \
C(blended_segment) 768.352015 2.0 0.389611
C(OP_single_segment) 525.478384 2.0 0.266456
C(blended_segment):C(OP_single_segment) 3542.688613 4.0 0.898202
Residual 79870.051753 81.0 NaN
PR(>F)
C(blended_segment) 0.678583
C(OP_single_segment) 0.766758
C(blended_segment):C(OP_single_segment) 0.469056
Residual NaN
Tukey's HSD test for blended_segment:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間 近い 6.8438 0.6722 -12.3224 26.0099 False
中間 遠い 5.5 0.7793 -13.962 24.962 False
近い 遠い -1.3438 0.9842 -20.1661 17.4786 False
-----------------------------------------------------
Tukey's HSD test for OP_single_segment:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間 近い -4.7771 0.8277 -24.2 14.6457 False
中間 遠い 0.3133 0.9992 -19.7726 20.3993 False
近い 遠い 5.0905 0.7885 -13.3641 23.545 False
-----------------------------------------------------
Tukey's HSD test for interaction groups:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間_中間 中間_近い -18.9167 0.9532 -68.9581 31.1248 False
中間_中間 中間_遠い -9.9667 0.9995 -61.6492 41.7159 False
中間_中間 近い_中間 -8.6042 0.9997 -56.5152 39.3069 False
中間_中間 近い_近い 1.9103 1.0 -47.4855 51.306 False
中間_中間 近い_遠い -13.8333 0.9994 -84.6026 56.9359 False
中間_中間 遠い_中間 -1.1667 1.0 -71.9359 69.6026 False
中間_中間 遠い_近い -16.2667 0.9846 -67.9492 35.4159 False
中間_中間 遠い_遠い -1.1078 1.0 -48.633 46.4173 False
中間_近い 中間_遠い 8.95 0.9991 -33.9029 51.8029 False
中間_近い 近い_中間 10.3125 0.9944 -27.9073 48.5323 False
中間_近い 近い_近い 20.8269 0.7703 -19.2383 60.8921 False
中間_近い 近い_遠い 5.0833 1.0 -59.5199 69.6865 False
中間_近い 遠い_中間 17.75 0.9937 -46.8532 82.3532 False
中間_近い 遠い_近い 2.65 1.0 -40.2029 45.5029 False
中間_近い 遠い_遠い 17.8088 0.8504 -19.9261 55.5438 False
中間_遠い 近い_中間 1.3625 1.0 -38.9822 41.7072 False
中間_遠い 近い_近い 11.8769 0.9924 -30.2202 53.974 False
中間_遠い 近い_遠い -3.8667 1.0 -69.7493 62.0159 False
中間_遠い 遠い_中間 8.8 1.0 -57.0826 74.6826 False
中間_遠い 遠い_近い -6.3 1.0 -51.0584 38.4584 False
中間_遠い 遠い_遠い 8.8588 0.9986 -31.0269 48.7445 False
近い_中間 近い_近い 10.5144 0.9926 -26.8559 47.8848 False
近い_中間 近い_遠い -5.2292 1.0 -68.1966 57.7383 False
近い_中間 遠い_中間 7.4375 1.0 -55.5299 70.4049 False
近い_中間 遠い_近い -7.6625 0.9995 -48.0072 32.6822 False
近い_中間 遠い_遠い 7.4963 0.9989 -27.3641 42.3567 False
近い_近い 近い_遠い -15.7436 0.9971 -79.8479 48.3607 False
近い_近い 遠い_中間 -3.0769 1.0 -67.1813 61.0274 False
近い_近い 遠い_近い -18.1769 0.9035 -60.274 23.9202 False
近い_近い 遠い_遠い -3.0181 1.0 -39.8924 33.8562 False
近い_遠い 遠い_中間 12.6667 0.9999 -69.0506 94.384 False
近い_遠い 遠い_近い -2.4333 1.0 -68.3159 63.4493 False
近い_遠い 遠い_遠い 12.7255 0.9992 -49.9488 75.3998 False
遠い_中間 遠い_近い -15.1 0.9982 -80.9826 50.7826 False
遠い_中間 遠い_遠い 0.0588 1.0 -62.6155 62.7331 False
遠い_近い 遠い_遠い 15.1588 0.9518 -24.7269 55.0445 False
-----------------------------------------------------
==================================================
OP - click_likelihood グループ平均:
OP_single_segment 近い 中間 遠い
blended_segment
近い 0.384615 -8.625000 -17.000000
中間 -21.250000 -0.666667 -11.700000
遠い -19.500000 1.666667 1.529412
OP - click_likelihood 二元配置分散分析結果:
sum_sq df F \
C(blended_segment) 1088.207212 2.0 0.510121
C(OP_single_segment) 1165.281498 2.0 0.546252
C(blended_segment):C(OP_single_segment) 4531.130094 4.0 1.062034
Residual 86395.912217 81.0 NaN
PR(>F)
C(blended_segment) 0.602339
C(OP_single_segment) 0.581235
C(blended_segment):C(OP_single_segment) 0.380764
Residual NaN
Tukey's HSD test for blended_segment:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間 近い 7.6786 0.6342 -12.397 27.7541 False
中間 遠い 7.9619 0.6221 -12.4235 28.3473 False
近い 遠い 0.2833 0.9994 -19.4321 19.9987 False
-----------------------------------------------------
Tukey's HSD test for OP_single_segment:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間 近い -7.2343 0.6734 -27.5408 13.0722 False
中間 遠い 0.7467 0.996 -20.2531 21.7464 False
近い 遠い 7.981 0.5874 -11.3132 27.2751 False
-----------------------------------------------------
Tukey's HSD test for interaction groups:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
======================================================
group1 group2 meandiff p-adj lower upper reject
------------------------------------------------------
中間_中間 中間_近い -20.5833 0.9397 -72.629 31.4623 False
中間_中間 中間_遠い -11.0333 0.9992 -64.7858 42.7192 False
中間_中間 近い_中間 -7.9583 0.9999 -57.7882 41.8716 False
中間_中間 近い_近い 1.0513 1.0 -50.3228 52.4253 False
中間_中間 近い_遠い -16.3333 0.9986 -89.937 57.2703 False
中間_中間 遠い_中間 2.3333 1.0 -71.2703 75.937 False
中間_中間 遠い_近い -18.8333 0.97 -72.5858 34.9192 False
中間_中間 遠い_遠い 2.1961 1.0 -47.2325 51.6247 False
中間_近い 中間_遠い 9.55 0.9989 -35.0192 54.1192 False
中間_近い 近い_中間 12.625 0.9837 -27.1255 52.3755 False
中間_近い 近い_近い 21.6346 0.7714 -20.0352 63.3045 False
中間_近い 近い_遠い 4.25 1.0 -62.9406 71.4406 False
中間_近い 遠い_中間 22.9167 0.9745 -44.274 90.1073 False
中間_近い 遠い_近い 1.75 1.0 -42.8192 46.3192 False
中間_近い 遠い_遠い 22.7794 0.6492 -16.4668 62.0257 False
中間_遠い 近い_中間 3.075 1.0 -38.8855 45.0355 False
中間_遠い 近い_近い 12.0846 0.9935 -31.6985 55.8677 False
中間_遠い 近い_遠い -5.3 1.0 -73.8213 63.2213 False
中間_遠い 遠い_中間 13.3667 0.9994 -55.1546 81.8879 False
中間_遠い 遠い_近い -7.8 0.9998 -54.351 38.751 False
中間_遠い 遠い_遠い 13.2294 0.9832 -28.2537 54.7126 False
近い_中間 近い_近い 9.0096 0.998 -29.8574 47.8767 False
近い_中間 近い_遠い -8.375 1.0 -73.8643 57.1143 False
近い_中間 遠い_中間 10.2917 0.9999 -55.1977 75.781 False
近い_中間 遠い_近い -10.875 0.9957 -52.8355 31.0855 False
近い_中間 遠い_遠い 10.1544 0.9928 -26.1022 46.411 False
近い_近い 近い_遠い -17.3846 0.9956 -84.0564 49.2872 False
近い_近い 遠い_中間 1.2821 1.0 -65.3897 67.9538 False
近い_近い 遠い_近い -19.8846 0.8756 -63.6677 23.8985 False
近い_近い 遠い_遠い 1.1448 1.0 -37.2064 39.496 False
近い_遠い 遠い_中間 18.6667 0.9987 -66.3235 103.6568 False
近い_遠い 遠い_近い -2.5 1.0 -71.0213 66.0213 False
近い_遠い 遠い_遠い 18.5294 0.992 -46.6551 83.7139 False
遠い_中間 遠い_近い -21.1667 0.9863 -89.6879 47.3546 False
遠い_中間 遠い_遠い -0.1373 1.0 -65.3217 65.0472 False
遠い_近い 遠い_遠い 21.0294 0.7935 -20.4537 62.5126 False
------------------------------------------------------
==================================================
CO - preference グループ平均:
CO_single_segment 近い 中間 遠い
blended_segment
近い -2.500000 6.785714 4.250000
中間 -8.937500 -15.500000 -12.500000
遠い 4.727273 -19.333333 8.076923
CO - preference 二元配置分散分析結果:
sum_sq df F \
C(blended_segment) 3549.700477 2.0 1.835519
C(CO_single_segment) 716.571248 2.0 0.370533
C(blended_segment):C(CO_single_segment) 3280.341119 4.0 0.848118
Residual 78322.732871 81.0 NaN
PR(>F)
C(blended_segment) 0.166104
C(CO_single_segment) 0.691531
C(blended_segment):C(CO_single_segment) 0.498858
Residual NaN
Tukey's HSD test for blended_segment:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間 近い 14.3571 0.1744 -4.6233 33.3376 False
中間 遠い 12.4738 0.276 -6.7997 31.7473 False
近い 遠い -1.8833 0.9685 -20.5233 16.7567 False
-----------------------------------------------------
Tukey's HSD test for CO_single_segment:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間 近い 1.2495 0.9867 -17.841 20.3399 False
中間 遠い 6.755 0.7127 -13.7426 27.2526 False
近い 遠い 5.5055 0.7669 -13.3762 24.3872 False
-----------------------------------------------------
Tukey's HSD test for interaction groups:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間_中間 中間_近い 6.5625 1.0 -40.8822 54.0072 False
中間_中間 中間_遠い 3.0 1.0 -54.2204 60.2204 False
中間_中間 近い_中間 22.2857 0.8665 -26.0744 70.6458 False
中間_中間 近い_近い 13.0 0.9963 -38.1795 64.1795 False
中間_中間 近い_遠い 19.75 0.9593 -33.7748 73.2748 False
中間_中間 遠い_中間 -3.8333 1.0 -61.0538 53.3871 False
中間_中間 遠い_近い 20.2273 0.9339 -30.0723 70.5268 False
中間_中間 遠い_遠い 23.5769 0.835 -25.338 72.4918 False
中間_近い 中間_遠い -3.5625 1.0 -51.0072 43.8822 False
中間_近い 近い_中間 15.7232 0.9015 -20.5468 51.9933 False
中間_近い 近い_近い 6.4375 0.9999 -33.5145 46.3895 False
中間_近い 近い_遠い 13.1875 0.9868 -29.7278 56.1028 False
中間_近い 遠い_中間 -10.3958 0.9987 -57.8405 37.0488 False
中間_近い 遠い_近い 13.6648 0.9692 -25.1536 52.4831 False
中間_近い 遠い_遠い 17.0144 0.8679 -19.9922 54.021 False
中間_遠い 近い_中間 19.2857 0.9368 -29.0744 67.6458 False
中間_遠い 近い_近い 10.0 0.9994 -41.1795 61.1795 False
中間_遠い 近い_遠い 16.75 0.9851 -36.7748 70.2748 False
中間_遠い 遠い_中間 -6.8333 1.0 -64.0538 50.3871 False
中間_遠い 遠い_近い 17.2273 0.9739 -33.0723 67.5268 False
中間_遠い 遠い_遠い 20.5769 0.9157 -28.338 69.4918 False
近い_中間 近い_近い -9.2857 0.9983 -50.3206 31.7492 False
近い_中間 近い_遠い -2.5357 1.0 -46.4609 41.3895 False
近い_中間 遠い_中間 -26.119 0.7317 -74.4791 22.241 False
近い_中間 遠い_近い -2.0584 1.0 -41.9905 37.8736 False
近い_中間 遠い_遠い 1.2912 1.0 -36.8819 39.4643 False
近い_近い 近い_遠い 6.75 0.9999 -40.2614 53.7614 False
近い_近い 遠い_中間 -16.8333 0.9796 -68.0128 34.3462 False
近い_近い 遠い_近い 7.2273 0.9998 -36.0764 50.531 False
近い_近い 遠い_遠い 10.5769 0.9963 -31.1104 52.2642 False
近い_遠い 遠い_中間 -23.5833 0.893 -77.1081 29.9415 False
近い_遠い 遠い_近い 0.4773 1.0 -45.5746 46.5291 False
近い_遠い 遠い_遠い 3.8269 1.0 -40.7084 48.3622 False
遠い_中間 遠い_近い 24.0606 0.8407 -26.2389 74.3602 False
遠い_中間 遠い_遠い 27.4103 0.691 -21.5046 76.3252 False
遠い_近い 遠い_遠い 3.3497 1.0 -37.2525 43.9518 False
-----------------------------------------------------
==================================================
CO - believability グループ平均:
CO_single_segment 近い 中間 遠い
blended_segment
近い 0.000000 6.000000 9.250000
中間 -6.375000 -12.166667 -6.666667
遠い 7.636364 -17.833333 0.153846
CO - believability 二元配置分散分析結果:
sum_sq df F \
C(blended_segment) 2793.648687 2.0 1.705229
C(CO_single_segment) 759.149125 2.0 0.463381
C(blended_segment):C(CO_single_segment) 2338.645256 4.0 0.713749
Residual 66350.487762 81.0 NaN
PR(>F)
C(blended_segment) 0.188189
C(CO_single_segment) 0.630810
C(blended_segment):C(CO_single_segment) 0.584920
Residual NaN
Tukey's HSD test for blended_segment:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間 近い 12.6161 0.2015 -4.8175 30.0496 False
中間 遠い 6.9786 0.6166 -10.7241 24.6813 False
近い 遠い -5.6375 0.7131 -22.7583 11.4833 False
-----------------------------------------------------
Tukey's HSD test for CO_single_segment:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間 近い 3.2058 0.9002 -14.2853 20.6969 False
中間 遠い 5.0256 0.7996 -13.7547 23.806 False
近い 遠い 1.8198 0.9659 -15.48 19.1197 False
-----------------------------------------------------
Tukey's HSD test for interaction groups:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間_中間 中間_近い 5.7917 1.0 -37.8766 49.4599 False
中間_中間 中間_遠い 5.5 1.0 -47.1659 58.1659 False
中間_中間 近い_中間 18.1667 0.9283 -26.3441 62.6774 False
中間_中間 近い_近い 12.1667 0.9958 -34.9391 59.2724 False
中間_中間 近い_遠い 21.4167 0.9001 -27.8477 70.6811 False
中間_中間 遠い_中間 -5.6667 1.0 -58.3325 46.9992 False
中間_中間 遠い_近い 19.803 0.9081 -26.4928 66.0989 False
中間_中間 遠い_遠い 12.3205 0.9938 -32.7009 57.3419 False
中間_近い 中間_遠い -0.2917 1.0 -43.9599 43.3766 False
中間_近い 近い_中間 12.375 0.9582 -21.0081 45.7581 False
中間_近い 近い_近い 6.375 0.9998 -30.3969 43.1469 False
中間_近い 近い_遠い 15.625 0.9396 -23.8744 55.1244 False
中間_近い 遠い_中間 -11.4583 0.9954 -55.1266 32.2099 False
中間_近い 遠い_近い 14.0114 0.9424 -21.7172 49.7399 False
中間_近い 遠い_遠い 6.5288 0.9995 -27.5321 40.5898 False
中間_遠い 近い_中間 12.6667 0.992 -31.8441 57.1774 False
中間_遠い 近い_近い 6.6667 0.9999 -40.4391 53.7724 False
中間_遠い 近い_遠い 15.9167 0.9818 -33.3477 65.1811 False
中間_遠い 遠い_中間 -11.1667 0.999 -63.8325 41.4992 False
中間_遠い 遠い_近い 14.303 0.9863 -31.9928 60.5989 False
中間_遠い 遠い_遠い 6.8205 0.9999 -38.2009 51.8419 False
近い_中間 近い_近い -6.0 0.9999 -43.7686 31.7686 False
近い_中間 近い_遠い 3.25 1.0 -37.1789 43.6789 False
近い_中間 遠い_中間 -23.8333 0.7408 -68.3441 20.6774 False
近い_中間 遠い_近い 1.6364 1.0 -35.1172 38.3899 False
近い_中間 遠い_遠い -5.8462 0.9998 -40.9808 29.2885 False
近い_近い 近い_遠い 9.25 0.9989 -34.0194 52.5194 False
近い_近い 遠い_中間 -17.8333 0.9528 -64.9391 29.2724 False
近い_近い 遠い_近い 7.6364 0.9995 -32.2205 47.4932 False
近い_近い 遠い_遠い 0.1538 1.0 -38.2153 38.523 False
近い_遠い 遠い_中間 -27.0833 0.7126 -76.3477 22.1811 False
近い_遠い 遠い_近い -1.6136 1.0 -43.9999 40.7726 False
近い_遠い 遠い_遠い -9.0962 0.9986 -50.0866 31.8943 False
遠い_中間 遠い_近い 25.4697 0.7118 -20.8262 71.7656 False
遠い_中間 遠い_遠い 17.9872 0.9362 -27.0343 63.0086 False
遠い_近い 遠い_遠い -7.4825 0.9993 -44.8529 29.8879 False
-----------------------------------------------------
==================================================
CO - overall_liking グループ平均:
CO_single_segment 近い 中間 遠い
blended_segment
近い -3.400000 1.857143 -1.0
中間 -9.187500 -17.000000 -12.0
遠い 7.272727 -27.000000 7.0
CO - overall_liking 二元配置分散分析結果:
sum_sq df F \
C(blended_segment) 2785.900299 2.0 1.342870
C(CO_single_segment) 1553.964153 2.0 0.749048
C(blended_segment):C(CO_single_segment) 4468.566528 4.0 1.076978
Residual 84020.733604 81.0 NaN
PR(>F)
C(blended_segment) 0.266845
C(CO_single_segment) 0.476063
C(blended_segment):C(CO_single_segment) 0.373413
Residual NaN
Tukey's HSD test for blended_segment:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間 近い 10.9643 0.3896 -8.8867 30.8152 False
中間 遠い 11.7643 0.3497 -8.3931 31.9217 False
近い 遠い 0.8 0.9947 -18.6948 20.2948 False
-----------------------------------------------------
Tukey's HSD test for CO_single_segment:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間 近い 6.4241 0.7193 -13.3407 26.1889 False
中間 遠い 9.5613 0.5325 -11.6604 30.7829 False
近い 遠い 3.1371 0.9225 -16.4116 22.6858 False
-----------------------------------------------------
Tukey's HSD test for interaction groups:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間_中間 中間_近い 7.8125 0.9999 -41.3277 56.9527 False
中間_中間 中間_遠い 5.0 1.0 -54.2653 64.2653 False
中間_中間 近い_中間 18.8571 0.9543 -31.2312 68.9454 False
中間_中間 近い_近い 13.6 0.996 -39.4085 66.6085 False
中間_中間 近い_遠い 16.0 0.9912 -39.4376 71.4376 False
中間_中間 遠い_中間 -10.0 0.9998 -69.2653 49.2653 False
中間_中間 遠い_近い 24.2727 0.8592 -27.8244 76.3698 False
中間_中間 遠い_遠い 24.0 0.8477 -26.663 74.663 False
中間_近い 中間_遠い -2.8125 1.0 -51.9527 46.3277 False
中間_近い 近い_中間 11.0446 0.9901 -26.5216 48.6109 False
中間_近い 近い_近い 5.7875 1.0 -35.5922 47.1672 False
中間_近い 近い_遠い 8.1875 0.9996 -36.2615 52.6365 False
中間_近い 遠い_中間 -17.8125 0.9633 -66.9527 31.3277 False
中間_近い 遠い_近い 16.4602 0.9271 -23.7454 56.6658 False
中間_近い 遠い_遠い 16.1875 0.914 -22.1416 54.5166 False
中間_遠い 近い_中間 13.8571 0.9934 -36.2312 63.9454 False
中間_遠い 近い_近い 8.6 0.9999 -44.4085 61.6085 False
中間_遠い 近い_遠い 11.0 0.9994 -44.4376 66.4376 False
中間_遠い 遠い_中間 -15.0 0.9964 -74.2653 44.2653 False
中間_遠い 遠い_近い 19.2727 0.9587 -32.8244 71.3698 False
中間_遠い 遠い_遠い 19.0 0.9553 -31.663 69.663 False
近い_中間 近い_近い -5.2571 1.0 -47.7585 37.2442 False
近い_中間 近い_遠い -2.8571 1.0 -48.3521 42.6378 False
近い_中間 遠い_中間 -28.8571 0.6583 -78.9454 21.2312 False
近い_中間 遠い_近い 5.4156 1.0 -35.9435 46.7746 False
近い_中間 遠い_遠い 5.1429 1.0 -34.3945 44.6802 False
近い_近い 近い_遠い 2.4 1.0 -46.2914 51.0914 False
近い_近い 遠い_中間 -23.6 0.8873 -76.6085 29.4085 False
近い_近い 遠い_近い 10.6727 0.9976 -34.1785 55.5239 False
近い_近い 遠い_遠い 10.4 0.9974 -32.7771 53.5771 False
近い_遠い 遠い_中間 -26.0 0.8548 -81.4376 29.4376 False
近い_遠い 遠い_近い 8.2727 0.9998 -39.4249 55.9703 False
近い_遠い 遠い_遠い 8.0 0.9998 -38.1269 54.1269 False
遠い_中間 遠い_近い 34.2727 0.4828 -17.8244 86.3698 False
遠い_中間 遠い_遠い 34.0 0.455 -16.663 84.663 False
遠い_近い 遠い_遠い -0.2727 1.0 -42.3259 41.7804 False
-----------------------------------------------------
==================================================
CO - persuasiveness グループ平均:
CO_single_segment 近い 中間 遠い
blended_segment
近い -8.800000 4.357143 6.750000
中間 -11.500000 -18.666667 -3.833333
遠い 9.363636 -19.000000 3.615385
CO - persuasiveness 二元配置分散分析結果:
sum_sq df F \
C(blended_segment) 2800.405491 2.0 1.543961
C(CO_single_segment) 1144.470450 2.0 0.630986
C(blended_segment):C(CO_single_segment) 4155.123542 4.0 1.145432
Residual 73458.103330 81.0 NaN
PR(>F)
C(blended_segment) 0.219751
C(CO_single_segment) 0.534662
C(blended_segment):C(CO_single_segment) 0.341213
Residual NaN
Tukey's HSD test for blended_segment:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
====================================================
group1 group2 meandiff p-adj lower upper reject
----------------------------------------------------
中間 近い 12.2366 0.2633 -6.3287 30.8019 False
中間 遠い 12.5929 0.2542 -6.259 31.4447 False
近い 遠い 0.3562 0.9988 -17.876 18.5885 False
----------------------------------------------------
Tukey's HSD test for CO_single_segment:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間 近い 1.7786 0.9716 -16.773 20.3302 False
中間 遠い 9.235 0.5133 -10.684 29.1541 False
近い 遠い 7.4565 0.5983 -10.8923 25.8052 False
-----------------------------------------------------
Tukey's HSD test for interaction groups:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間_中間 中間_近い 7.1667 0.9999 -38.781 53.1143 False
中間_中間 中間_遠い 14.8333 0.9947 -40.5816 70.2483 False
中間_中間 近い_中間 23.0238 0.8196 -23.8104 69.858 False
中間_中間 近い_近い 9.8667 0.9993 -39.698 59.4313 False
中間_中間 近い_遠い 25.4167 0.8217 -26.4193 77.2526 False
中間_中間 遠い_中間 -0.3333 1.0 -55.7483 55.0816 False
中間_中間 遠い_近い 28.0303 0.6598 -20.6822 76.7428 False
中間_中間 遠い_遠い 22.2821 0.8527 -25.0894 69.6535 False
中間_近い 中間_遠い 7.6667 0.9998 -38.281 53.6143 False
中間_近い 近い_中間 15.8571 0.8792 -19.2685 50.9828 False
中間_近い 近い_近い 2.7 1.0 -35.9914 41.3914 False
中間_近い 近い_遠い 18.25 0.8948 -23.3112 59.8112 False
中間_近い 遠い_中間 -7.5 0.9998 -53.4477 38.4477 False
中間_近い 遠い_近い 20.8636 0.702 -16.7299 58.4572 False
中間_近い 遠い_遠い 15.1154 0.9146 -20.7235 50.9543 False
中間_遠い 近い_中間 8.1905 0.9997 -38.6437 55.0247 False
中間_遠い 近い_近い -4.9667 1.0 -54.5313 44.598 False
中間_遠い 近い_遠い 10.5833 0.9992 -41.2526 62.4193 False
中間_遠い 遠い_中間 -15.1667 0.9938 -70.5816 40.2483 False
中間_遠い 遠い_近い 13.197 0.9942 -35.5155 61.9094 False
中間_遠い 遠い_遠い 7.4487 0.9999 -39.9228 54.8202 False
近い_中間 近い_近い -13.1571 0.9788 -52.8973 26.583 False
近い_中間 近い_遠い 2.3929 1.0 -40.1464 44.9321 False
近い_中間 遠い_中間 -23.3571 0.8077 -70.1913 23.477 False
近い_中間 遠い_近い 5.0065 1.0 -33.6656 43.6785 False
近い_中間 遠い_遠い -0.7418 1.0 -37.7104 36.2269 False
近い_近い 近い_遠い 15.55 0.9743 -29.978 61.078 False
近い_近い 遠い_中間 -10.2 0.9992 -59.7646 39.3646 False
近い_近い 遠い_近い 18.1636 0.902 -23.7737 60.101 False
近い_近い 遠い_遠い 12.4154 0.9867 -27.9566 52.7873 False
近い_遠い 遠い_中間 -25.75 0.811 -77.5859 26.0859 False
近い_遠い 遠い_近い 2.6136 1.0 -41.9852 47.2124 False
近い_遠い 遠い_遠い -3.1346 1.0 -46.2647 39.9955 False
遠い_中間 遠い_近い 28.3636 0.6453 -20.3488 77.0761 False
遠い_中間 遠い_遠い 22.6154 0.8421 -24.7561 69.9869 False
遠い_近い 遠い_遠い -5.7483 0.9999 -45.0693 33.5728 False
-----------------------------------------------------
==================================================
CO - interest グループ平均:
CO_single_segment 近い 中間 遠い
blended_segment
近い -6.500000 4.857143 9.250000
中間 -7.250000 -23.166667 -14.666667
遠い 6.818182 -16.000000 7.153846
CO - interest 二元配置分散分析結果:
sum_sq df F \
C(blended_segment) 4222.747678 2.0 2.136318
C(CO_single_segment) 1270.394098 2.0 0.642702
C(blended_segment):C(CO_single_segment) 3671.565028 4.0 0.928736
Residual 80054.209624 81.0 NaN
PR(>F)
C(blended_segment) 0.124695
C(CO_single_segment) 0.528530
C(blended_segment):C(CO_single_segment) 0.451528
Residual NaN
Tukey's HSD test for blended_segment:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間 近い 14.6562 0.1717 -4.6303 33.9428 False
中間 遠い 14.65 0.1811 -4.9343 34.2343 False
近い 遠い -0.0063 1.0 -18.9469 18.9344 False
-----------------------------------------------------
Tukey's HSD test for CO_single_segment:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間 近い 3.5582 0.9001 -15.8431 22.9595 False
中間 遠い 9.349 0.5351 -11.4824 30.1804 False
近い 遠い 5.7908 0.7526 -13.3983 24.9799 False
-----------------------------------------------------
Tukey's HSD test for interaction groups:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間_中間 中間_近い 15.9167 0.9785 -32.0496 63.8829 False
中間_中間 中間_遠い 8.5 0.9999 -49.3494 66.3494 False
中間_中間 近い_中間 28.0238 0.6645 -20.8679 76.9155 False
中間_中間 近い_近い 16.6667 0.9821 -35.0755 68.4088 False
中間_中間 近い_遠い 32.4167 0.6094 -21.6965 86.5299 False
中間_中間 遠い_中間 7.1667 1.0 -50.6828 65.0161 False
中間_中間 遠い_近い 29.9848 0.6296 -20.8677 80.8373 False
中間_中間 遠い_遠い 30.3205 0.5791 -19.1321 79.7731 False
中間_近い 中間_遠い -7.4167 0.9999 -55.3829 40.5496 False
中間_近い 近い_中間 12.1071 0.9792 -24.5616 48.7759 False
中間_近い 近い_近い 0.75 1.0 -39.6412 41.1412 False
中間_近い 近い_遠い 16.5 0.9516 -26.8871 59.8871 False
中間_近い 遠い_中間 -8.75 0.9997 -56.7162 39.2162 False
中間_近い 遠い_近い 14.0682 0.9657 -25.1769 53.3133 False
中間_近い 遠い_遠い 14.4038 0.9481 -23.0096 51.8172 False
中間_遠い 近い_中間 19.5238 0.9363 -29.3679 68.4155 False
中間_遠い 近い_近い 8.1667 0.9999 -43.5755 59.9088 False
中間_遠い 近い_遠い 23.9167 0.8913 -30.1965 78.0299 False
中間_遠い 遠い_中間 -1.3333 1.0 -59.1828 56.5161 False
中間_遠い 遠い_近い 21.4848 0.9138 -29.3677 72.3373 False
中間_遠い 遠い_遠い 21.8205 0.8922 -27.6321 71.2731 False
近い_中間 近い_近い -11.3571 0.9938 -52.8431 30.1288 False
近い_中間 近い_遠い 4.3929 1.0 -40.0152 48.801 False
近い_中間 遠い_中間 -20.8571 0.9093 -69.7488 28.0346 False
近い_中間 遠い_近い 1.961 1.0 -38.41 42.332 False
近い_中間 遠い_遠い 2.2967 1.0 -36.2961 40.8895 False
近い_近い 近い_遠い 15.75 0.9787 -31.7782 63.2782 False
近い_近い 遠い_中間 -9.5 0.9996 -61.2421 42.2421 False
近い_近い 遠い_近い 13.3182 0.9876 -30.4616 57.0979 False
近い_近い 遠い_遠い 13.6538 0.9815 -28.4917 55.7994 False
近い_遠い 遠い_中間 -25.25 0.8582 -79.3632 28.8632 False
近い_遠い 遠い_近い -2.4318 1.0 -48.9899 44.1263 False
近い_遠い 遠い_遠い -2.0962 1.0 -47.1211 42.9288 False
遠い_中間 遠い_近い 22.8182 0.8828 -28.0343 73.6707 False
遠い_中間 遠い_遠い 23.1538 0.8559 -26.2988 72.6065 False
遠い_近い 遠い_遠い 0.3357 1.0 -40.7128 41.3842 False
-----------------------------------------------------
==================================================
CO - click_likelihood グループ平均:
CO_single_segment 近い 中間 遠い
blended_segment
近い -5.500000 6.571429 7.875000
中間 -13.000000 -22.500000 -12.166667
遠い 7.454545 -17.000000 4.307692
CO - click_likelihood 二元配置分散分析結果:
sum_sq df F \
C(blended_segment) 5581.678828 2.0 2.377340
C(CO_single_segment) 817.864049 2.0 0.348343
C(blended_segment):C(CO_single_segment) 3265.231114 4.0 0.695361
Residual 95088.633408 81.0 NaN
PR(>F)
C(blended_segment) 0.099243
C(CO_single_segment) 0.706909
C(blended_segment):C(CO_single_segment) 0.597332
Residual NaN
Tukey's HSD test for blended_segment:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間 近い 17.9821 0.1047 -2.8507 38.815 False
中間 遠い 16.0571 0.1723 -5.0973 37.2116 False
近い 遠い -1.925 0.9726 -22.3842 18.5342 False
-----------------------------------------------------
Tukey's HSD test for CO_single_segment:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間 近い 0.685 0.9967 -20.406 21.7761 False
中間 遠い 7.2806 0.7244 -15.3651 29.9263 False
近い 遠い 6.5956 0.7321 -14.2648 27.456 False
-----------------------------------------------------
Tukey's HSD test for interaction groups:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間_中間 中間_近い 9.5 0.9997 -42.7767 61.7767 False
中間_中間 中間_遠い 10.3333 0.9998 -52.7147 73.3813 False
中間_中間 近い_中間 29.0714 0.7209 -24.2139 82.3567 False
中間_中間 近い_近い 17.0 0.9883 -39.3919 73.3919 False
中間_中間 近い_遠い 30.375 0.779 -28.601 89.351 False
中間_中間 遠い_中間 5.5 1.0 -57.548 68.548 False
中間_中間 遠い_近い 29.9545 0.731 -25.4678 85.3768 False
中間_中間 遠い_遠い 26.8077 0.8099 -27.0889 80.7043 False
中間_近い 中間_遠い 0.8333 1.0 -51.4433 53.11 False
中間_近い 近い_中間 19.5714 0.8226 -20.3925 59.5354 False
中間_近い 近い_近い 7.5 0.9998 -36.5209 51.5209 False
中間_近い 近い_遠い 20.875 0.892 -26.411 68.161 False
中間_近い 遠い_中間 -4.0 1.0 -56.2767 48.2767 False
中間_近い 遠い_近い 20.4545 0.8409 -22.3173 63.2264 False
中間_近い 遠い_遠い 17.3077 0.9117 -23.4678 58.0832 False
中間_遠い 近い_中間 18.7381 0.9694 -34.5472 72.0234 False
中間_遠い 近い_近い 6.6667 1.0 -49.7252 63.0585 False
中間_遠い 近い_遠い 20.0417 0.9751 -38.9344 79.0177 False
中間_遠い 遠い_中間 -4.8333 1.0 -67.8813 58.2147 False
中間_遠い 遠い_近い 19.6212 0.9681 -35.8011 75.0435 False
中間_遠い 遠い_遠い 16.4744 0.9872 -37.4223 70.371 False
近い_中間 近い_近い -12.0714 0.9948 -57.2855 33.1426 False
近い_中間 近い_遠い 1.3036 1.0 -47.0952 49.7023 False
近い_中間 遠い_中間 -23.5714 0.8908 -76.8567 29.7139 False
近い_中間 遠い_近い 0.8831 1.0 -43.1158 44.882 False
近い_中間 遠い_遠い -2.2637 1.0 -44.3246 39.7971 False
近い_近い 近い_遠い 13.375 0.9958 -38.4242 65.1742 False
近い_近い 遠い_中間 -11.5 0.9992 -67.8919 44.8919 False
近い_近い 遠い_近い 12.9545 0.9941 -34.7594 60.6685 False
近い_近い 遠い_遠い 9.8077 0.9989 -36.1253 55.7406 False
近い_遠い 遠い_中間 -24.875 0.9146 -83.851 34.101 False
近い_遠い 遠い_近い -0.4205 1.0 -51.1624 50.3215 False
近い_遠い 遠い_遠い -3.5673 1.0 -52.6383 45.5037 False
遠い_中間 遠い_近い 24.4545 0.8922 -30.9678 79.8768 False
遠い_中間 遠い_遠い 21.3077 0.9398 -32.5889 75.2043 False
遠い_近い 遠い_遠い -3.1469 1.0 -47.8841 41.5904 False
-----------------------------------------------------
==================================================
AG - preference グループ平均:
AG_single_segment 近い 中間 遠い
blended_segment
近い 15.916667 -0.437500 14.500000
中間 8.600000 7.142857 27.666667
遠い 13.571429 -3.000000 11.733333
AG - preference 二元配置分散分析結果:
sum_sq df F \
C(blended_segment) 428.485786 2.0 0.308816
C(AG_single_segment) 3790.920933 2.0 2.732169
C(blended_segment):C(AG_single_segment) 1464.135614 4.0 0.527611
Residual 56194.292262 81.0 NaN
PR(>F)
C(blended_segment) 0.735177
C(AG_single_segment) 0.071079
C(blended_segment):C(AG_single_segment) 0.715732
Residual NaN
Tukey's HSD test for blended_segment:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間 近い -4.7589 0.7688 -21.1578 11.64 False
中間 遠い -4.0881 0.8283 -20.7401 12.5639 False
近い 遠い 0.6708 0.9946 -15.4339 16.7755 False
-----------------------------------------------------
Tukey's HSD test for AG_single_segment:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間 近い 11.593 0.1734 -3.7077 26.8936 False
中間 遠い 15.3871 0.0742 -1.175 31.9492 False
近い 遠い 3.7941 0.843 -12.4385 20.0268 False
-----------------------------------------------------
Tukey's HSD test for interaction groups:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間_中間 中間_近い 1.4571 1.0 -36.9693 39.8836 False
中間_中間 中間_遠い 20.5238 0.8944 -26.1809 67.2285 False
中間_中間 近い_中間 -7.5804 0.9993 -45.6228 30.4621 False
中間_中間 近い_近い 8.7738 0.9987 -31.1517 48.6994 False
中間_中間 近い_遠い 7.3571 1.0 -45.2605 59.9748 False
中間_中間 遠い_中間 -10.1429 0.9979 -53.5904 33.3047 False
中間_中間 遠い_近い 6.4286 0.9999 -38.4439 51.301 False
中間_中間 遠い_遠い 4.5905 1.0 -33.836 43.017 False
中間_近い 中間_遠い 19.0667 0.853 -21.4844 59.6177 False
中間_近い 近い_中間 -9.0375 0.9888 -39.2085 21.1335 False
中間_近い 近い_近い 7.3167 0.9984 -25.1965 39.8298 False
中間_近い 近い_遠い 5.9 1.0 -41.3406 53.1406 False
中間_近い 遠い_中間 -11.6 0.9843 -48.3525 25.1525 False
中間_近い 遠い_近い 4.9714 1.0 -33.455 43.3979 False
中間_近い 遠い_遠い 3.1333 1.0 -27.5204 33.7871 False
中間_遠い 近い_中間 -28.1042 0.3975 -68.2915 12.0832 False
中間_遠い 近い_近い -11.75 0.9928 -53.7243 30.2243 False
中間_遠い 近い_遠い -13.1667 0.9973 -67.3553 41.022 False
中間_遠い 遠い_中間 -30.6667 0.4439 -76.0041 14.6708 False
中間_遠い 遠い_近い -14.0952 0.9882 -60.8 32.6095 False
中間_遠い 遠い_遠い -15.9333 0.9418 -56.4844 24.6177 False
近い_中間 近い_近い 16.3542 0.7878 -15.7043 48.4126 False
近い_中間 近い_遠い 14.9375 0.9834 -31.9912 61.8662 False
近い_中間 遠い_中間 -2.5625 1.0 -38.9133 33.7883 False
近い_中間 遠い_近い 14.0089 0.9598 -24.0335 52.0514 False
近い_中間 遠い_遠い 12.1708 0.9327 -18.0001 42.3418 False
近い_近い 近い_遠い -1.4167 1.0 -49.8845 47.0511 False
近い_近い 遠い_中間 -18.9167 0.8161 -57.2338 19.4005 False
近い_近い 遠い_近い -2.3452 1.0 -42.2708 37.5803 False
近い_近い 遠い_遠い -4.1833 1.0 -36.6965 28.3298 False
近い_遠い 遠い_中間 -17.5 0.9748 -68.9079 33.9079 False
近い_遠い 遠い_近い -0.9286 1.0 -53.5462 51.689 False
近い_遠い 遠い_遠い -2.7667 1.0 -50.0072 44.4739 False
遠い_中間 遠い_近い 16.5714 0.9508 -26.8761 60.019 False
遠い_中間 遠い_遠い 14.7333 0.935 -22.0192 51.4859 False
遠い_近い 遠い_遠い -1.8381 1.0 -40.2646 36.5884 False
-----------------------------------------------------
==================================================
AG - believability グループ平均:
AG_single_segment 近い 中間 遠い
blended_segment
近い 20.750000 4.875000 26.750000
中間 13.266667 14.285714 24.666667
遠い 14.428571 -2.625000 6.200000
AG - believability 二元配置分散分析結果:
sum_sq df F \
C(blended_segment) 2051.965989 2.0 1.825976
C(AG_single_segment) 2536.196268 2.0 2.256877
C(blended_segment):C(AG_single_segment) 1661.575160 4.0 0.739290
Residual 45512.434524 81.0 NaN
PR(>F)
C(blended_segment) 0.167628
C(AG_single_segment) 0.111221
C(blended_segment):C(AG_single_segment) 0.567917
Residual NaN
Tukey's HSD test for blended_segment:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間 近い -2.4018 0.9203 -17.1513 12.3478 False
中間 遠い -10.1976 0.2412 -25.1748 4.7796 False
近い 遠い -7.7958 0.4084 -22.2808 6.6891 False
-----------------------------------------------------
Tukey's HSD test for AG_single_segment:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間 近い 11.0825 0.1517 -3.0028 25.1679 False
中間 遠い 8.8555 0.3532 -6.3912 24.1021 False
近い 遠い -2.2271 0.9328 -17.1704 12.7163 False
-----------------------------------------------------
Tukey's HSD test for interaction groups:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間_中間 中間_近い -1.019 1.0 -35.601 33.5629 False
中間_中間 中間_遠い 10.381 0.9969 -31.651 52.4129 False
中間_中間 近い_中間 -9.4107 0.9936 -43.6471 24.8257 False
中間_中間 近い_近い 6.4643 0.9997 -29.4668 42.3953 False
中間_中間 近い_遠い 12.4643 0.9953 -34.889 59.8176 False
中間_中間 遠い_中間 -16.9107 0.9027 -56.0114 22.19 False
中間_中間 遠い_近い 0.1429 1.0 -40.2402 40.5259 False
中間_中間 遠い_遠い -8.0857 0.9979 -42.6677 26.4962 False
中間_近い 中間_遠い 11.4 0.9853 -25.094 47.894 False
中間_近い 近い_中間 -8.3917 0.9863 -35.5441 18.7607 False
中間_近い 近い_近い 7.4833 0.9961 -21.7769 36.7436 False
中間_近い 近い_遠い 13.4833 0.9838 -29.0309 55.9975 False
中間_近い 遠い_中間 -15.8917 0.8374 -48.9671 17.1838 False
中間_近い 遠い_近い 1.1619 1.0 -33.42 35.7439 False
中間_近い 遠い_遠い -7.0667 0.9961 -34.6535 20.5202 False
中間_遠い 近い_中間 -19.7917 0.7176 -55.9583 16.375 False
中間_遠い 近い_近い -3.9167 1.0 -41.6915 33.8582 False
中間_遠い 近い_遠い 2.0833 1.0 -46.6838 50.8505 False
中間_遠い 遠い_中間 -27.2917 0.4596 -68.0932 13.5098 False
中間_遠い 遠い_近い -10.2381 0.9972 -52.2701 31.7939 False
中間_遠い 遠い_遠い -18.4667 0.7951 -54.9606 18.0273 False
近い_中間 近い_近い 15.875 0.7116 -12.976 44.726 False
近い_中間 近い_遠い 21.875 0.7737 -20.3586 64.1086 False
近い_中間 遠い_中間 -7.5 0.9982 -40.214 25.214 False
近い_中間 遠い_近い 9.5536 0.993 -24.6828 43.7899 False
近い_中間 遠い_遠い 1.325 1.0 -25.8274 28.4774 False
近い_近い 近い_遠い 6.0 1.0 -37.6186 49.6186 False
近い_近い 遠い_中間 -23.375 0.441 -57.8586 11.1086 False
近い_近い 遠い_近い -6.3214 0.9997 -42.2525 29.6096 False
近い_近い 遠い_遠い -14.55 0.8101 -43.8103 14.7103 False
近い_遠い 遠い_中間 -29.375 0.5319 -75.6396 16.8896 False
近い_遠い 遠い_近い -12.3214 0.9956 -59.6747 35.0319 False
近い_遠い 遠い_遠い -20.55 0.8329 -63.0642 21.9642 False
遠い_中間 遠い_近い 17.0536 0.8984 -22.0471 56.1543 False
遠い_中間 遠い_遠い 8.825 0.9948 -24.2505 41.9005 False
遠い_近い 遠い_遠い -8.2286 0.9976 -42.8105 26.3534 False
-----------------------------------------------------
==================================================
AG - overall_liking グループ平均:
AG_single_segment 近い 中間 遠い
blended_segment
近い 18.000000 2.125000 16.500000
中間 9.866667 11.857143 28.666667
遠い 4.857143 -4.250000 8.600000
AG - overall_liking 二元配置分散分析結果:
sum_sq df F \
C(blended_segment) 2211.689771 2.0 1.409393
C(AG_single_segment) 3004.895325 2.0 1.914861
C(blended_segment):C(AG_single_segment) 1362.952294 4.0 0.434269
Residual 63554.630952 81.0 NaN
PR(>F)
C(blended_segment) 0.250218
C(AG_single_segment) 0.153974
C(blended_segment):C(AG_single_segment) 0.783483
Residual NaN
Tukey's HSD test for blended_segment:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間 近い -4.5179 0.8069 -21.7589 12.7231 False
中間 遠い -10.0929 0.3586 -27.6 7.4143 False
近い 遠い -5.575 0.7131 -22.5067 11.3567 False
-----------------------------------------------------
Tukey's HSD test for AG_single_segment:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間 近い 9.0285 0.3941 -7.42 25.477 False
中間 遠い 12.0026 0.248 -5.8021 29.8072 False
近い 遠い 2.9741 0.9131 -14.4763 20.4246 False
-----------------------------------------------------
Tukey's HSD test for interaction groups:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間_中間 中間_近い -1.9905 1.0 -42.8561 38.8751 False
中間_中間 中間_遠い 16.8095 0.9757 -32.8598 66.4789 False
中間_中間 近い_中間 -9.7321 0.9975 -50.1894 30.7251 False
中間_中間 近い_近い 6.1429 0.9999 -36.317 48.6027 False
中間_中間 近い_遠い 4.6429 1.0 -51.3147 60.6004 False
中間_中間 遠い_中間 -16.1071 0.9709 -62.3126 30.0983 False
中間_中間 遠い_近い -7.0 0.9999 -54.7208 40.7208 False
中間_中間 遠い_遠い -3.2571 1.0 -44.1228 37.6085 False
中間_近い 中間_遠い 18.8 0.8986 -24.3251 61.9251 False
中間_近い 近い_中間 -7.7417 0.9974 -39.8277 24.3444 False
中間_近い 近い_近い 8.1333 0.9978 -26.4436 42.7103 False
中間_近い 近い_遠い 6.6333 1.0 -43.6058 56.8725 False
中間_近い 遠い_中間 -14.1167 0.9641 -53.2021 24.9687 False
中間_近い 遠い_近い -5.0095 1.0 -45.8751 35.8561 False
中間_近い 遠い_遠い -1.2667 1.0 -33.8661 31.3328 False
中間_遠い 近い_中間 -26.5417 0.562 -69.2799 16.1966 False
中間_遠い 近い_近い -10.6667 0.9976 -55.3053 33.972 False
中間_遠い 近い_遠い -12.1667 0.999 -69.795 45.4616 False
中間_遠い 遠い_中間 -32.9167 0.431 -81.132 15.2986 False
中間_遠い 遠い_近い -23.8095 0.8391 -73.4789 25.8598 False
中間_遠い 遠い_遠い -20.0667 0.8601 -63.1917 23.0584 False
近い_中間 近い_近い 15.875 0.8596 -18.2184 49.9684 False
近い_中間 近い_遠い 14.375 0.9913 -35.5326 64.2826 False
近い_中間 遠い_中間 -6.375 0.9998 -45.0332 32.2832 False
近い_中間 遠い_近い 2.7321 1.0 -37.7251 43.1894 False
近い_中間 遠い_遠い 6.475 0.9993 -25.6111 38.5611 False
近い_近い 近い_遠い -1.5 1.0 -53.0443 50.0443 False
近い_近い 遠い_中間 -22.25 0.72 -62.9994 18.4994 False
近い_近い 遠い_近い -13.1429 0.9861 -55.6027 29.317 False
近い_近い 遠い_遠い -9.4 0.9941 -43.977 25.177 False
近い_遠い 遠い_中間 -20.75 0.9521 -75.421 33.921 False
近い_遠い 遠い_近い -11.6429 0.9991 -67.6004 44.3147 False
近い_遠い 遠い_遠い -7.9 0.9999 -58.1392 42.3392 False
遠い_中間 遠い_近い 9.1071 0.9994 -37.0983 55.3126 False
遠い_中間 遠い_遠い 12.85 0.9797 -26.2354 51.9354 False
遠い_近い 遠い_遠い 3.7429 1.0 -37.1228 44.6085 False
-----------------------------------------------------
==================================================
AG - persuasiveness グループ平均:
AG_single_segment 近い 中間 遠い
blended_segment
近い 12.083333 -1.187500 26.000000
中間 6.666667 8.142857 22.833333
遠い 3.857143 0.250000 7.600000
AG - persuasiveness 二元配置分散分析結果:
sum_sq df F \
C(blended_segment) 1075.221091 2.0 0.792152
C(AG_single_segment) 2922.075661 2.0 2.152793
C(blended_segment):C(AG_single_segment) 1364.830887 4.0 0.502759
Residual 54972.335119 81.0 NaN
PR(>F)
C(blended_segment) 0.456346
C(AG_single_segment) 0.122760
C(blended_segment):C(AG_single_segment) 0.733772
Residual NaN
Tukey's HSD test for blended_segment:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間 近い -3.3125 0.876 -19.4165 12.7915 False
中間 遠い -5.7333 0.6818 -22.0859 10.6193 False
近い 遠い -2.4208 0.9293 -18.2359 13.3943 False
-----------------------------------------------------
Tukey's HSD test for AG_single_segment:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
====================================================
group1 group2 meandiff p-adj lower upper reject
----------------------------------------------------
中間 近い 6.7097 0.5465 -8.5019 21.9212 False
中間 遠い 12.9097 0.1537 -3.556 29.3754 False
近い 遠い 6.2 0.6317 -9.9381 22.3381 False
----------------------------------------------------
Tukey's HSD test for interaction groups:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間_中間 中間_近い -1.4762 1.0 -39.4826 36.5302 False
中間_中間 中間_遠い 14.6905 0.9835 -31.5037 60.8846 False
中間_中間 近い_中間 -9.3304 0.9969 -46.9569 28.2962 False
中間_中間 近い_近い 3.9405 1.0 -35.5486 43.4296 False
中間_中間 近い_遠い 17.8571 0.9736 -34.1852 69.8995 False
中間_中間 遠い_中間 -7.8929 0.9996 -50.8654 35.0797 False
中間_中間 遠い_近い -4.2857 1.0 -48.6676 40.0962 False
中間_中間 遠い_遠い -0.5429 1.0 -38.5492 37.4635 False
中間_近い 中間_遠い 16.1667 0.933 -23.9411 56.2744 False
中間_近い 近い_中間 -7.8542 0.9953 -37.6953 21.9869 False
中間_近い 近い_近い 5.4167 0.9998 -26.7411 37.5744 False
中間_近い 近い_遠い 19.3333 0.9228 -27.3908 66.0574 False
中間_近い 遠い_中間 -6.4167 0.9997 -42.7674 29.9341 False
中間_近い 遠い_近い -2.8095 1.0 -40.8159 35.1969 False
中間_近い 遠い_遠い 0.9333 1.0 -29.3853 31.2519 False
中間_遠い 近い_中間 -24.0208 0.5981 -63.7689 15.7272 False
中間_遠い 近い_近い -10.75 0.9958 -52.2655 30.7655 False
中間_遠い 近い_遠い 3.1667 1.0 -50.4296 56.7629 False
中間_遠い 遠い_中間 -22.5833 0.7993 -67.4252 22.2585 False
中間_遠い 遠い_近い -18.9762 0.9258 -65.1703 27.2179 False
中間_遠い 遠い_遠い -15.2333 0.9519 -55.3411 24.8744 False
近い_中間 近い_近い 13.2708 0.918 -18.4371 44.9788 False
近い_中間 近い_遠い 27.1875 0.6379 -19.2282 73.6032 False
近い_中間 遠い_中間 1.4375 1.0 -34.5159 37.3909 False
近い_中間 遠い_近い 5.0446 1.0 -32.5819 42.6712 False
近い_中間 遠い_遠い 8.7875 0.99 -21.0536 38.6286 False
近い_近い 近い_遠い 13.9167 0.9909 -34.0213 61.8546 False
近い_近い 遠い_中間 -11.8333 0.9853 -49.7316 26.0649 False
近い_近い 遠い_近い -8.2262 0.9991 -47.7153 31.2629 False
近い_近い 遠い_遠い -4.4833 1.0 -36.6411 27.6744 False
近い_遠い 遠い_中間 -25.75 0.7944 -76.5958 25.0958 False
近い_遠い 遠い_近い -22.1429 0.9106 -74.1852 29.8995 False
近い_遠い 遠い_遠い -18.4 0.9411 -65.1241 28.3241 False
遠い_中間 遠い_近い 3.6071 1.0 -39.3654 46.5797 False
遠い_中間 遠い_遠い 7.35 0.9993 -29.0007 43.7007 False
遠い_近い 遠い_遠い 3.7429 1.0 -34.2635 41.7492 False
-----------------------------------------------------
==================================================
AG - interest グループ平均:
AG_single_segment 近い 中間 遠い
blended_segment
近い 14.750000 0.812500 16.250000
中間 6.200000 5.714286 30.000000
遠い 5.428571 -3.000000 8.666667
AG - interest 二元配置分散分析結果:
sum_sq df F \
C(blended_segment) 1322.106044 2.0 0.913956
C(AG_single_segment) 3542.228616 2.0 2.448699
C(blended_segment):C(AG_single_segment) 1523.333586 4.0 0.526531
Residual 58586.313690 81.0 NaN
PR(>F)
C(blended_segment) 0.405029
C(AG_single_segment) 0.092780
C(blended_segment):C(AG_single_segment) 0.716515
Residual NaN
Tukey's HSD test for blended_segment:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間 近い -3.2098 0.8907 -19.9 13.4804 False
中間 遠い -6.3786 0.6434 -23.3264 10.5693 False
近い 遠い -3.1688 0.8896 -19.5595 13.222 False
-----------------------------------------------------
Tukey's HSD test for AG_single_segment:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間 近い 8.1233 0.4382 -7.6117 23.8583 False
中間 遠い 14.0645 0.126 -2.9678 31.0968 False
近い 遠い 5.9412 0.6739 -10.7523 22.6347 False
-----------------------------------------------------
Tukey's HSD test for interaction groups:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間_中間 中間_近い 0.4857 1.0 -38.7501 39.7215 False
中間_中間 中間_遠い 24.2857 0.7894 -23.4027 71.9741 False
中間_中間 近い_中間 -4.9018 1.0 -43.7455 33.9419 False
中間_中間 近い_近い 9.0357 0.9986 -31.7307 49.8022 False
中間_中間 近い_遠い 10.5357 0.9994 -43.1901 64.2615 False
中間_中間 遠い_中間 -8.7143 0.9994 -53.0769 35.6484 False
中間_中間 遠い_近い -0.2857 1.0 -46.1033 45.5318 False
中間_中間 遠い_遠い 2.9524 1.0 -36.2834 42.1882 False
中間_近い 中間_遠い 23.8 0.6611 -17.6051 65.2051 False
中間_近い 近い_中間 -5.3875 0.9997 -36.1939 25.4189 False
中間_近い 近い_近い 8.55 0.9959 -24.648 41.748 False
中間_近い 近い_遠い 10.05 0.9991 -38.1855 58.2855 False
中間_近い 遠い_中間 -9.2 0.9971 -46.7266 28.3266 False
中間_近い 遠い_近い -0.7714 1.0 -40.0072 38.4644 False
中間_近い 遠い_遠い 2.4667 1.0 -28.8327 33.766 False
中間_遠い 近い_中間 -29.1875 0.3741 -70.2213 11.8463 False
中間_遠い 近い_近い -15.25 0.9671 -58.1084 27.6084 False
中間_遠い 近い_遠い -13.75 0.9968 -69.0799 41.5799 False
中間_遠い 遠い_中間 -33.0 0.3711 -79.2923 13.2923 False
中間_遠い 遠い_近い -24.5714 0.7786 -72.2598 23.117 False
中間_遠い 遠い_遠い -21.3333 0.7787 -62.7385 20.0718 False
近い_中間 近い_近い 13.9375 0.9102 -18.7961 46.6711 False
近い_中間 近い_遠い 15.4375 0.9821 -32.4796 63.3546 False
近い_中間 遠い_中間 -3.8125 1.0 -40.929 33.304 False
近い_中間 遠い_近い 4.6161 1.0 -34.2276 43.4598 False
近い_中間 遠い_遠い 7.8542 0.9962 -22.9522 38.6606 False
近い_近い 近い_遠い 1.5 1.0 -47.9886 50.9886 False
近い_近い 遠い_中間 -17.75 0.8762 -56.8742 21.3742 False
近い_近い 遠い_近い -9.3214 0.9982 -50.0879 31.445 False
近い_近い 遠い_遠い -6.0833 0.9996 -39.2813 27.1146 False
近い_遠い 遠い_中間 -19.25 0.9607 -71.7406 33.2406 False
近い_遠い 遠い_近い -10.8214 0.9993 -64.5473 42.9044 False
近い_遠い 遠い_遠い -7.5833 0.9999 -55.8189 40.6522 False
遠い_中間 遠い_近い 8.4286 0.9995 -35.9341 52.7912 False
遠い_中間 遠い_遠い 11.6667 0.9857 -25.8599 49.1933 False
遠い_近い 遠い_遠い 3.2381 1.0 -35.9977 42.4739 False
-----------------------------------------------------
==================================================
AG - click_likelihood グループ平均:
AG_single_segment 近い 中間 遠い
blended_segment
近い 16.916667 -0.812500 18.500000
中間 13.200000 6.285714 30.666667
遠い 5.000000 -9.375000 13.866667
AG - click_likelihood 二元配置分散分析結果:
sum_sq df F \
C(blended_segment) 2173.221732 2.0 1.347180
C(AG_single_segment) 6912.886454 2.0 4.285298
C(blended_segment):C(AG_single_segment) 595.903427 4.0 0.184700
Residual 65333.124405 81.0 NaN
PR(>F)
C(blended_segment) 0.265734
C(AG_single_segment) 0.017019
C(blended_segment):C(AG_single_segment) 0.945734
Residual NaN
Tukey's HSD test for blended_segment:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間 近い -6.9643 0.6228 -24.8187 10.8902 False
中間 遠い -9.6143 0.419 -27.7443 8.5158 False
近い 遠い -2.65 0.931 -20.1842 14.8842 False
-----------------------------------------------------
Tukey's HSD test for AG_single_segment:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
====================================================
group1 group2 meandiff p-adj lower upper reject
----------------------------------------------------
中間 近い 14.2429 0.1065 -2.3244 30.8102 False
中間 遠い 20.0594 0.0245 2.1262 37.9926 True
近い 遠い 5.8165 0.7107 -11.76 23.3929 False
----------------------------------------------------
Tukey's HSD test for interaction groups:
Multiple Comparison of Means - Tukey HSD, FWER=0.05
=====================================================
group1 group2 meandiff p-adj lower upper reject
-----------------------------------------------------
中間_中間 中間_近い 6.9143 0.9998 -34.5192 48.3477 False
中間_中間 中間_遠い 24.381 0.8316 -25.9786 74.7405 False
中間_中間 近い_中間 -7.0982 0.9998 -48.1176 33.9212 False
中間_中間 近い_近い 10.631 0.9969 -32.4189 53.6808 False
中間_中間 近い_遠い 12.2143 0.9988 -44.5208 68.9494 False
中間_中間 遠い_中間 -15.6607 0.9775 -62.5082 31.1867 False
中間_中間 遠い_近い -1.2857 1.0 -49.6696 47.0981 False
中間_中間 遠い_遠い 7.581 0.9996 -33.8525 49.0144 False
中間_近い 中間_遠い 17.4667 0.9362 -26.2576 61.191 False
中間_近い 近い_中間 -14.0125 0.9047 -46.5444 18.5194 False
中間_近い 近い_近い 3.7167 1.0 -31.3408 38.7741 False
中間_近い 近い_遠い 5.3 1.0 -45.6373 56.2373 False
中間_近い 遠い_中間 -22.575 0.6718 -62.2035 17.0535 False
中間_近い 遠い_近い -8.2 0.9994 -49.6335 33.2335 False
中間_近い 遠い_遠い 0.6667 1.0 -32.3858 33.7191 False
中間_遠い 近い_中間 -31.4792 0.3455 -74.8113 11.853 False
中間_遠い 近い_近い -13.75 0.9877 -59.0089 31.5089 False
中間_遠い 近い_遠い -12.1667 0.9991 -70.5957 46.2624 False
中間_遠い 遠い_中間 -40.0417 0.1986 -88.9269 8.8436 False
中間_遠い 遠い_近い -25.6667 0.7886 -76.0262 24.6928 False
中間_遠い 遠い_遠い -16.8 0.9487 -60.5243 26.9243 False
近い_中間 近い_近い 17.7292 0.7829 -16.8379 52.2963 False
近い_中間 近い_遠い 19.3125 0.9506 -31.2885 69.9135 False
近い_中間 遠い_中間 -8.5625 0.9987 -47.7579 30.6329 False
近い_中間 遠い_近い 5.8125 0.9999 -35.2069 46.8319 False
近い_中間 遠い_遠い 14.6792 0.8795 -17.8528 47.2111 False
近い_近い 近い_遠い 1.5833 1.0 -50.6772 53.8439 False
近い_近い 遠い_中間 -26.2917 0.5288 -67.6072 15.0239 False
近い_近い 遠い_近い -11.9167 0.9933 -54.9665 31.1332 False
近い_近い 遠い_遠い -3.05 1.0 -38.1074 32.0074 False
近い_遠い 遠い_中間 -27.875 0.8005 -83.3057 27.5557 False
近い_遠い 遠い_近い -13.5 0.9976 -70.2351 43.2351 False
近い_遠い 遠い_遠い -4.6333 1.0 -55.5706 46.3039 False
遠い_中間 遠い_近い 14.375 0.9869 -32.4725 61.2225 False
遠い_中間 遠い_遠い 23.2417 0.6364 -16.3868 62.8702 False
遠い_近い 遠い_遠い 8.8667 0.9989 -32.5668 50.3001 False
-----------------------------------------------------
==================================================
linear regression¶
Features to be regressed:
- [y] each of the constructs(same questions for 4 different(big5) personalized contents) vs [X] big5 distances, controlling for socioeconomic
- [y] 'perceived_credibility' scores for each of 4 versions vs [X] 'perceived_personalization' scores for each of 4 versions & matched big5 scores for each of 4 versions, controlling for socioeconomic
- [y] 'overall_attitude' scores for each of 4 versions vs [X] 'perceived_personalization' scores for each of 4 versions & (moderator) 'perceived_credibility' scores for each of 4 versions & matched big5 scores for each of 4 versions, controlling for socioeconomic
- [y] 'ads_engagement' scores for each of 4 versions vs [X] 'overall_attitude' scores for each of 4 versions & matched big5 scores for each of 4 versions, controlling for socioeconomic
In [ ]: